Author Topic: CPU capacity switcher for 2 or more rendering processes on one computer  (Read 4126 times)

2017-10-12, 22:39:03

Bormax

  • Active Users
  • **
  • Posts: 568
    • View Profile
Hello guys!

I work as an architect and visualizer and do my job mostly on single computer. I use commercial render farm to render big size pictures, but most of the time I need to render a lot of medium size exterior images for client's or city's approval. Normally 2.4k pictures are enough, and in this case render farms are not very useful because it takes longer time to clean/prepare/pack/send/receive files for them than to render set of pictures on my computer.
As many of you I have 2,3 or sometimes more project which I have to work on at the same time. In this case most useful workflow is to start render picture in first Max window for one project and work with another one in second Max window doing some modeling or other work which doesn't need intensive CPU's job. But even working like this I need to make some fast renders and all these times I have the same question -

Is it possible to have some kind of switcher which can give let's say 99% of CPU capacity to the rendering which I start in second Max window, keeping 1% of CPU capacity for the  first Max window just to keep rendering running without need to stop and start it again, and give whole CPU power back to the first Max window when I stop rendering in Max window number 2?

2017-10-13, 08:32:48
Reply #1

Frood

  • Active Users
  • **
  • Posts: 2001
    • View Profile
    • Rakete GmbH
1. Manual solution: taks manager -> details -> 3dsmax.exe -> right click -> affinity and priority
2. Corona solution: render setup -> system -> system settings -> "# of threads"


Good Luck


Never underestimate the power of a well placed level one spell.

2017-10-13, 10:06:10
Reply #2

Ondra

  • Administrator
  • Active Users
  • *****
  • Posts: 9048
  • Turning coffee to features since 2009
    • View Profile
if you do the affinity solution, treat every 2 threads (0 and 1, 2 and 3, ...) as single entity, since they run on the same core and assigning each to different application would randomly shift resources between the two
Rendering is magic.How to get minidumps for crashed/frozen 3ds Max | Sorry for short replies, brief responses = more time to develop Corona ;)

2017-10-13, 18:43:11
Reply #3

Bormax

  • Active Users
  • **
  • Posts: 568
    • View Profile
Thank you guys!

I didn't know that it's possible to change number of threads in Corona during rendering, I'll keep it in mind! Unfortunately there is still problem to use Forest pack with Edge option from Boundary checking section (I reported about it here https://forum.corona-renderer.com/index.php/topic,16135.msg101906.html#msg101906) which I use in all exterior scenes so I have to Lock Max UI to avoid this problem, and it makes impossible to change settings during rendering. But this solution can be used for interior scenes
"Task manager solution" is good enough, so I'll go with this for work with exterior projects - thanks for the idea!

But actually is it possible to automate this procedure and create the "swing" system which can give all but 1 processor's thread to the active renderer in current window, and give all but 1 threads back to the secondary window if render in current window stopped?

2017-10-13, 19:00:20
Reply #4

Bormax

  • Active Users
  • **
  • Posts: 568
    • View Profile
I've done some tests, and have to say that  Corona solution doesn't work in this case. Yes, I can change number of threads during rendering, but it doesn't affect to the current rendering, Corona starts to use changed number of threads only after render stopped and started again (according to the task manager's statistic)
Task manager solution works right away

2017-10-13, 19:12:25
Reply #5

Frood

  • Active Users
  • **
  • Posts: 2001
    • View Profile
    • Rakete GmbH
But actually is it possible to automate this procedure and create the "swing" system

You may do something similar with process priority only: assign your rendering max instance "low" or even "idle" priority and your working instance "normal" or one above. Now, when you render in your working instance, you should get most of the cpu power which is then given back to the "low" or "idle" max process when you are doing nothing.

Furthermore you could think about submitting your renderjobs on your local machine via Backburner as network render job (less resources needed) and check in a startup script if max is currently in network mode. It's a one-liner and would set process priority automatically to low for BB jobs:

Code: [Select]
if (isnetserver()) do sysinfo.maxpriority = #low;

Good Luck



Never underestimate the power of a well placed level one spell.

2017-10-13, 19:39:24
Reply #6

Bormax

  • Active Users
  • **
  • Posts: 568
    • View Profile