Basically it's an issue I've been suffering with my last 2 projects (PC specs at the end).
PROBLEM: When I'm exporting the project via Media Encoder (H264, as usual) in some point my PC start to look like an old 286 PC. Everything become choppy. For example, when I move a window, it freezes a bit each second. Obviously I can't do anything while exporting... even writing this is slow.
ANALYSIS: What I saw is an After Effects task in Task Manager even if I close AE (maybe that task have always been there, I've never seen it), and it tooks 100% GPU! (it goes from 0 to 100 intermittently).
Strangest thing here is I've set Media Encoder to render Software Only.
I experiment this issue specially while rendering a bit complex scene.
QUESTION(S): How can be that an AE task is running? (maybe Dynamic Link?) And most important... what can I do to prevent this? (I've worked in AE for many years and this never happened to me).
Setting Media Encoder to Software Only doesn't do what you think it does and that's a whole other complicated topic. As for the hanging AE process, have you restarted your computer to see if it goes away? How about forgetting AME for a moment and just quitting AE, does the prorcess disappear then? You didn't say what you were doing in AME, but given that you mentioned Dynamic Link, does that mean you sent a comp from the Render Queue to AME?
There's lots to troubleshoot here, but I would start by only working with After Effects and trying what I mentioned above. I would also try exporting a file directly from the Render Queue to something like ProRes. Does the GPU go wild then? Does the same thing happen with the GPU when you're playing back your timeline in full res inside AE?
I actually have tried exporting directly from AE, and the same part of the video goes slow. But yes, I send the main comp to AME from AE (like always I've do).
The thing here is that if I use AME for exporting, an AE task appears (even if AE is closed), sucking all the PC resources. The question is this: it is a regular thing that AE task (that sucks it all) appear while AME is running? (maybe it is, and it's just my project)
I've end the AE task manually... and it appears again, so I assume it's necessary to be there.
Regarding your last questiosn, yes. It goes wild even if I render from AE... maybe it's just the project... I don't know.
All signs point to a heavy section of your project. And when you send a comp from AE to AME, a 'headless' (that means no UI) version of AE is actually the thing doing the rendering.
I would try upgrading to AE 2022 and using the new multi-frame rendering feature (enabled by default). I'm seeing performance improvements of 2-4x faster in rendering. MFR also works when you send a comp to AME 2022.