Jump to content
You must now use your email address to sign in [click for more info] ×

Affinity Photo memory usage/relinquishing questions


Recommended Posts

I have 64GB in my Intel Mac (specs below). Affinity Photo uses a whole lot of that, especially when I have multiple pictures open with Save History With Doc enabled.

And that's fine.

The issue is that it doesn't relinquish all that RAM when I quit the program. I'm not ready to use words like "memory leak' that are supposed to make one sound intelligent, but something doesn't seem right.

Memory Clean (I think that's the utility's name) is unable to free up the RAM.

This isn't a huge deal, except that I run music software that uses a whole lot of RAM as well, and I'm not used to having to restart before launching it. It does become unreliable very quickly if I don't.

So two questions:

1. Is it just me?

2. Is this better in M1/M2 Macs? Just curious, because I'm planning on upgrading to a Mac Studio in the near future.

Computer specs: Mac Pro 5,1, 12x3.46 GHz, 64MB RAM, Radeon RX 560 4 GB video card, macOS 10.14.6 Mojave. All SSDs, not using spinning drives.

TIA 

Link to comment
Share on other sites

  • Staff

Hi NickBatz, 

This doesn't seem to happen when I try some tests here. As far as I'm aware we might hold onto the RAM until something else needs it but it should be immediately free'd up for use once it's needed. Would you be able to provide a screenshot of Activity monitor on your mac showing the RAM usage before and after closing Affinity?

Thanks
C

Please tag me using @ in your reply so I can be sure to respond ASAP.

Link to comment
Share on other sites

15 hours ago, nickbatz said:

The issue is that it doesn't relinquish all that RAM when I quit the program.

If you have really quit the program, shouldn't it be the responsibility of the OS to make sure that everything was cleaned up?

-- Walt
Designer, Photo, and Publisher V1 and V2 at latest retail and beta releases
PC:
    Desktop:  Windows 11 Pro, version 23H2, 64GB memory, AMD Ryzen 9 5900 12-Core @ 3.00 GHz, NVIDIA GeForce RTX 3090 

    Laptop:  Windows 11 Pro, version 23H2, 32GB memory, Intel Core i7-10750H @ 2.60GHz, Intel UHD Graphics Comet Lake GT2 and NVIDIA GeForce RTX 3070 Laptop GPU.
iPad:  iPad Pro M1, 12.9": iPadOS 17.4.1, Apple Pencil 2, Magic Keyboard 
Mac:  2023 M2 MacBook Air 15", 16GB memory, macOS Sonoma 14.4.1

Link to comment
Share on other sites

7 minutes ago, walt.farrell said:

If you have really quit the program, shouldn't it be the responsibility of the OS to make sure that everything was cleaned up?

Yes, but only if the application releases the memory correctly, see https://en.wikipedia.org/wiki/Memory_leak.

  • where a program can request memory, such as shared memory, that is not released, even when the program terminates
     

 

Affinity Store (MSI/EXE): Affinity Suite (ADe, APh, APu) 2.4.0.2301
Dell OptiPlex 7060, i5-8500 3.00 GHz, 16 GB, Intel UHD Graphics 630, Dell P2417H 1920 x 1080, Windows 11 Pro, Version 23H2, Build 22631.3155.
Dell Latitude E5570, i5-6440HQ 2.60 GHz, 8 GB, Intel HD Graphics 530, 1920 x 1080, Windows 11 Pro, Version 23H2, Build 22631.3155.
Intel NUC5PGYH, Pentium N3700 2.40 GHz, 8 GB, Intel HD Graphics, EIZO EV2456 1920 x 1200, Windows 10 Pro, Version 21H1, Build 19043.2130.

Link to comment
Share on other sites

24 minutes ago, walt.farrell said:

If you have really quit the program, shouldn't it be the responsibility of the OS to make sure that everything was cleaned up?

 

17 minutes ago, Pšenda said:

Yes, but only if the application releases the memory correctly

 

Also, bear in mind that any information copied to the clipboard by the application is still there in memory when you close the application and nowadays you can have multiple items stored in the clipboard (clipboard history) You would, at least, need to flush the clipboard after closing the app to see if there are still missing chunks of memory

To save time I am currently using an automated AI to reply to some posts on this forum. If any of "my" posts are wrong or appear to be total b*ll*cks they are the ones generated by the AI. If correct they were probably mine. I apologise for any mistakes made by my AI - I'm sure it will improve with time.

Link to comment
Share on other sites

30 minutes ago, carl123 said:

Also, bear in mind that any information copied to the clipboard by the application is still there in memory when you close the application and nowadays you can have multiple items stored in the clipboard (clipboard history)

That is why some applications (e.g. even 20-year-old Word) warn when closing the application that a large amount of data has been copied to the Clipboard, and offer to release it.

Affinity Store (MSI/EXE): Affinity Suite (ADe, APh, APu) 2.4.0.2301
Dell OptiPlex 7060, i5-8500 3.00 GHz, 16 GB, Intel UHD Graphics 630, Dell P2417H 1920 x 1080, Windows 11 Pro, Version 23H2, Build 22631.3155.
Dell Latitude E5570, i5-6440HQ 2.60 GHz, 8 GB, Intel HD Graphics 530, 1920 x 1080, Windows 11 Pro, Version 23H2, Build 22631.3155.
Intel NUC5PGYH, Pentium N3700 2.40 GHz, 8 GB, Intel HD Graphics, EIZO EV2456 1920 x 1200, Windows 10 Pro, Version 21H1, Build 19043.2130.

Link to comment
Share on other sites

1 hour ago, carl123 said:

Also, bear in mind that any information copied to the clipboard by the application is still there in memory when you close the application....

Not so here on Mac OS with the Affinity applications. We loose whatever was in/on the clipboard when we quit the application. 

Mac Pro (Late 2013) Mac OS 12.7.4 
Affinity Designer 2.4.0 | Affinity Photo 2.4.0 | Affinity Publisher 2.4.0 | Beta versions as they appear.

I have never mastered color management, period, so I cannot help with that.

Link to comment
Share on other sites

1 minute ago, Old Bruce said:

Not so here on Mac OS with the Affinity applications. We loose whatever was in/on the clipboard when we quit the application. 

Interesting, does that apply to other apps on the Mac or just the Affinity ones?

To save time I am currently using an automated AI to reply to some posts on this forum. If any of "my" posts are wrong or appear to be total b*ll*cks they are the ones generated by the AI. If correct they were probably mine. I apologise for any mistakes made by my AI - I'm sure it will improve with time.

Link to comment
Share on other sites

21 minutes ago, carl123 said:

Interesting, does that apply to other apps on the Mac or just the Affinity ones?

... these are applications from the Apple Store or even those from the Affinity Store - so it's not just a consequence of sandboxing?

Which, by the way, could be an interesting addition from OP - from which store are the applications?

Affinity Store (MSI/EXE): Affinity Suite (ADe, APh, APu) 2.4.0.2301
Dell OptiPlex 7060, i5-8500 3.00 GHz, 16 GB, Intel UHD Graphics 630, Dell P2417H 1920 x 1080, Windows 11 Pro, Version 23H2, Build 22631.3155.
Dell Latitude E5570, i5-6440HQ 2.60 GHz, 8 GB, Intel HD Graphics 530, 1920 x 1080, Windows 11 Pro, Version 23H2, Build 22631.3155.
Intel NUC5PGYH, Pentium N3700 2.40 GHz, 8 GB, Intel HD Graphics, EIZO EV2456 1920 x 1200, Windows 10 Pro, Version 21H1, Build 19043.2130.

Link to comment
Share on other sites

10 hours ago, Callum said:

Hi NickBatz, 

This doesn't seem to happen when I try some tests here. As far as I'm aware we might hold onto the RAM until something else needs it but it should be immediately free'd up for use once it's needed. Would you be able to provide a screenshot of Activity monitor on your mac showing the RAM usage before and after closing Affinity?

Thanks
C

Okay, thanks, will do. It may be a couple of days, if that's okay.

Link to comment
Share on other sites

5 hours ago, carl123 said:

 

 

Also, bear in mind that any information copied to the clipboard by the application is still there in memory when you close the application and nowadays you can have multiple items stored in the clipboard (clipboard history) You would, at least, need to flush the clipboard after closing the app to see if there are still missing chunks of memory

Ah, I'll bet you're right.

Thanks.

Link to comment
Share on other sites

4 hours ago, carl123 said:

Interesting, does that apply to other apps on the Mac or just the Affinity ones?

From some quick & dirty tests, seems to be just the Affinity apps. I tested copying a chunk of text from each of the 3 apps (2 from the MAS & one from Affinity Store) to the clipboard & the clipboard was empty after I quit them. Same test with text in TextEdit, & with a Tiff copied to the clipboard in Preview left the items on the clipboard after those apps were quit.

All 3 1.10.8, & all 3 V2.4.1 Mac apps; 2020 iMac 27"; 3.8GHz i7, Radeon Pro 5700, 32GB RAM; macOS 10.15.7
Affinity Photo 
1.10.8; Affinity Designer 1.108; & all 3 V2 apps for iPad; 6th Generation iPad 32 GB; Apple Pencil; iPadOS 15.7

Link to comment
Share on other sites

On 7/19/2022 at 1:00 AM, Callum said:

Hi NickBatz, 

This doesn't seem to happen when I try some tests here. As far as I'm aware we might hold onto the RAM until something else needs it but it should be immediately free'd up for use once it's needed. Would you be able to provide a screenshot of Activity monitor on your mac showing the RAM usage before and after closing Affinity?

Thanks
C

 

Well, I just tried this again.

The first time I tried it, Affinity Photo didn't relinquish its RAM when I quit. I'd been working on one picture (a complicated one with lots and lots of layers), and don't know whether I had anything copied to Affinity's clipboard, 

Then I restarted, loaded a few pictures... and it did relinquish the RAM. I didn't have anything in the clipboard this time, but somehow I don't think that's the issue after all.

So I'm not sure where to go from here! There must be something going on to have caused it to happen the first time.

Link to comment
Share on other sites

After you quit Affinity Photo and start some other (non Affinity) application that needs lots of RAM does the RAM become available for the second application?

Mac Pro (Late 2013) Mac OS 12.7.4 
Affinity Designer 2.4.0 | Affinity Photo 2.4.0 | Affinity Publisher 2.4.0 | Beta versions as they appear.

I have never mastered color management, period, so I cannot help with that.

Link to comment
Share on other sites

21 hours ago, nickbatz said:

There must be something going on to have caused it to happen the first time.

And how do you know "it" happened? What makes you think that Affinity didn't release its memory, even when it was subsequently requested by another application?

Affinity Store (MSI/EXE): Affinity Suite (ADe, APh, APu) 2.4.0.2301
Dell OptiPlex 7060, i5-8500 3.00 GHz, 16 GB, Intel UHD Graphics 630, Dell P2417H 1920 x 1080, Windows 11 Pro, Version 23H2, Build 22631.3155.
Dell Latitude E5570, i5-6440HQ 2.60 GHz, 8 GB, Intel HD Graphics 530, 1920 x 1080, Windows 11 Pro, Version 23H2, Build 22631.3155.
Intel NUC5PGYH, Pentium N3700 2.40 GHz, 8 GB, Intel HD Graphics, EIZO EV2456 1920 x 1200, Windows 10 Pro, Version 21H1, Build 19043.2130.

Link to comment
Share on other sites

Macs come with a utility called Activity Monitor that can display the memory use - what's being used by programs, what's installed, etc. It's much like Task Manager on Windows.

I also have a utility called Memory Clean that has this info right in the menu bar.

54 minutes ago, Old Bruce said:

After you quit Affinity Photo and start some other (non Affinity) application that needs lots of RAM does the RAM become available for the second application?

I appreciate your attempt to help, but this is like calling an electrician because your power is out and being asked whether you can turn on the living room lights when you flip the switch on the wall. :)

Link to comment
Share on other sites

On 7/18/2022 at 11:06 PM, nickbatz said:

The issue is that it doesn't relinquish all that RAM when I quit the program.

Try some tool like Memory Diag and set it up to "Automatic recycle" when memory intensive apps (like APh etc.) are closed. You can also setup a "Limit in MB" for free memory, so the recycle runs when that limit value is reached!

memory_diag.jpg.2cf65dd9ad972ca9b7fedcd5fd28a68c.jpg

 

☛ Affinity Designer 1.10.8 ◆ Affinity Photo 1.10.8 ◆ Affinity Publisher 1.10.8 ◆ OSX El Capitan
☛ Affinity V2.3 apps ◆ MacOS Sonoma 14.2 ◆ iPad OS 17.2

Link to comment
Share on other sites

2 hours ago, nickbatz said:

Macs come with a utility called Activity Monitor that can display the memory use - what's being used by programs, what's installed, etc. It's much like Task Manager on Windows.

Where specifically in Activity Monitor do you see Affinity Photo still using memory after it has quit? Is it private memory (memory not available to other app because the OS has reserved it for the private use of AP), shared memory that other apps might still need to use, or what?

Remember that by design the macOS will not automatically clear recently used data from memory unless/until it is needed by some other process.

Basically, as long as the 'memory pressure' graph at the bottom of the Activity Monitor window stays green, everything should be OK.

All 3 1.10.8, & all 3 V2.4.1 Mac apps; 2020 iMac 27"; 3.8GHz i7, Radeon Pro 5700, 32GB RAM; macOS 10.15.7
Affinity Photo 
1.10.8; Affinity Designer 1.108; & all 3 V2 apps for iPad; 6th Generation iPad 32 GB; Apple Pencil; iPadOS 15.7

Link to comment
Share on other sites

59 minutes ago, R C-R said:

Where specifically in Activity Monitor do you see Affinity Photo still using memory after it has quit? Is it private memory (memory not available to other app because the OS has reserved it for the private use of AP), shared memory that other apps might still need to use, or what?

Remember that by design the macOS will not automatically clear recently used data from memory unless/until it is needed by some other process.

Basically, as long as the 'memory pressure' graph at the bottom of the Activity Monitor window stays green, everything should be OK.

It doesn't always free the memory when you quit the program so you can run other big programs, regardless of what should happen. Yes, I'm aware of the different kinds of memory use, and at one point I could have told you what they are.

This is my menu bar, which includes Memory Clean's display. It tells you how much application memory is free. Right now I have 39.51 GB free.

620558154_menubar.jpg.bcc780712f4491513147343c2efc50ae.jpg

Bottom line, something is going on, whether it's a real problem or just a quirk specific to my setup. My machine is frozen on an outdated macOS version (Mojave), and I don't expect Affinity to use it as a target.

As I said, I plan to update to a Mac Studio fairly soon.

Link to comment
Share on other sites

2 hours ago, v_kyr said:

Try some tool like Memory Diag and set it up to "Automatic recycle" when memory intensive apps (like APh etc.) are closed. You can also setup a "Limit in MB" for free memory, so the recycle runs when that limit value is reached!

 

 

 

I use Memory Clean, but I wouldn't want to have a utility do that automatically.

And I certainly wouldn't want to limit memory use! I run real-time music programs that stream samples off drives into head-start RAM buffers, and the last thing you want is for it to start using swapfiles instead of memory.

In general macOS does a great job of handling this seamlessly. I haven't actually had to use Memory Clean to regain RAM for years, but when I do it might free up 3GB. It used to make a much more dramatic difference.

Link to comment
Share on other sites

13 minutes ago, nickbatz said:

I use Memory Clean, but I wouldn't want to have a utility do that automatically.

Depends on you, you can but you don't have to setup/use such automatic tool option. It can of course also be manually triggert on demand if needed.

☛ Affinity Designer 1.10.8 ◆ Affinity Photo 1.10.8 ◆ Affinity Publisher 1.10.8 ◆ OSX El Capitan
☛ Affinity V2.3 apps ◆ MacOS Sonoma 14.2 ◆ iPad OS 17.2

Link to comment
Share on other sites

47 minutes ago, nickbatz said:

It doesn't always free the memory when you quit the program so you can run other big programs, regardless of what should happen. Yes, I'm aware of the different kinds of memory use, and at one point I could have told you what they are.

If by "it" you mean the macOS, then again what specifically is it that makes you think there is something wrong with AP if not all the memory it has used while open is cleared when you quit that app? Where in Activity Monitor or in Memory Clean or in any other app or utility do you see any indication of that?

If instead by "it" you mean AP itself, it is still unclear what makes you think something is wrong.

All 3 1.10.8, & all 3 V2.4.1 Mac apps; 2020 iMac 27"; 3.8GHz i7, Radeon Pro 5700, 32GB RAM; macOS 10.15.7
Affinity Photo 
1.10.8; Affinity Designer 1.108; & all 3 V2 apps for iPad; 6th Generation iPad 32 GB; Apple Pencil; iPadOS 15.7

Link to comment
Share on other sites

42 minutes ago, R C-R said:

If by "it" you mean the macOS, then again what specifically is it that makes you think there is something wrong with AP if not all the memory it has used while open is cleared when you quit that app? Where in Activity Monitor or in Memory Clean or in any other app or utility do you see any indication of that?

If instead by "it" you mean AP itself, it is still unclear what makes you think something is wrong.

 

Oh come on.

I appreciate your willingness to help, but this is just getting frustrating.

Please just look at my last post. Look at the picture of my menu bar.

Link to comment
Share on other sites

3 hours ago, nickbatz said:

This is my menu bar, which includes Memory Clean's display. It tells you how much application memory is free. Right now I have 39.51 GB free.

620558154_menubar.jpg.bcc780712f4491513147343c2efc50ae.jpg

1 hour ago, nickbatz said:

Look at the picture of my menu bar.

Does your menu bar tell anything about the 24 used GB, respectively about any Affinity app, either launched or quit?

The Activity Monitor.app can at least display the used memory of all active processes (in particular if those are checked in the menu). Also, if Affinity is launched, it can report the removable / deletable memory (I don't know exactly how it is called in the English version) if this column is activated, and, whether Affinity is in App Nap mode (which might allow macOS to move memory to its Swap (which is displayed at the bottom of this window). They all may help to detect what's going on – more verbose than your menu bar.

macOS 10.14.6 | MacBookPro Retina 15" | Eizo 27" | Affinity V1

Link to comment
Share on other sites

3 hours ago, nickbatz said:

Please just look at my last post. Look at the picture of my menu bar.

All that says is you have 39.51 GB free. It says nothing about memory pressure being sufficiently high enough to force releasing any more of it so other processes can use it. In fact, like has already been mentioned, absent high memory pressure the OS will try to avoid releasing recently used data already in memory in case it might be needed again because it is much quicker to move it from inactive to active memory than fetching it again from even the fastest SSD.

All 3 1.10.8, & all 3 V2.4.1 Mac apps; 2020 iMac 27"; 3.8GHz i7, Radeon Pro 5700, 32GB RAM; macOS 10.15.7
Affinity Photo 
1.10.8; Affinity Designer 1.108; & all 3 V2 apps for iPad; 6th Generation iPad 32 GB; Apple Pencil; iPadOS 15.7

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...

Important Information

Terms of Use | Privacy Policy | Guidelines | We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.