What I see at the moment is that cinema is not obeying slave GPU affinity when using octane to render?
I have 2 slaves per render node, each slave have GPU affinity and setup to use 2 GPUs.
Redshift with that works perfectly.
Octane is using all GPUs all the time.
I used option in render settings to turn off Use all GPUs but it doesn’t change a thing.
So running Octane cinema job using single slave that should use only two GPUs, I stills ee all 4 GPUs being used for rendering.
That is also big problem if running on all slaves then 2 octane cinema tasks are using same GPUs … = problems.
To make things short, how can I force Octane to use only GPUs that are assigned to slave in GPU affinity settings?
Thank you
I did some spelunking into the C4D Batch plugin, and it looks like we don’t have code to control Octane at the moment.
GPU affinity is a very application / plugin specific feature as operating systems don’t expose this to use as generically as CPU affinity. That means that we need to discover how to control it and usually that means how to control it within the application. For Redshift, that’s via a command line flag to Cinema 4D itself.
Does anyone know how we can control Octane’s affinity either from the command line or from within Cinema’s API?
I’ll go add it as a developer issue. It’ll take some time to test.
My quick guess as to how this could work:
selectedGPUs = 1,2,3,4,5 # this comes from a helper function elsewhere in the plugin
if len( selectedGPUs ) > 0:
octane_gpus = '-octaneGPU "'
for a in range(16): # We can't detect how many GPUs are on a system, but we only support specifying 16
is_selected = str(a in selectedGPUs).lower()
octane_gpus += "{0}:{1} ".format(a, is_selected)
octane_gpus += '"'
print(octane_gpus)
I’ve actually been testing this recently with Octane 3.08 w/ C4D R19 and due to some issues with our multi-gpu machine we haven’t gotten around to testing if it’s actually respecting what gpus are being set on the command-line.
If anyone’s down for a quick test or two, I’d appreciate it if they could run similar command-line options and try turning on/off gpus the way that’s suggested and post their results here.
I’ve made the changes to the plugin and submission files for C4D (for recent versions of Deadline 10). If you get a chance to test it out, please let us know your results here! Would be greatly appreciated!
Instructions:
Download and un-zip the contents of the attached file
Back-up your existing cinema 4d files that you’re about to overwrite
Copy “Cinema4DSubmission.py” to “DeadlineRepository10/scripts/Submission”
Copy “SubmitC4DToDeadline.py” to “DeadlineRepository10/submission/Cinema4D/Main”
Copy “Cinema4D.py” to “DeadlineRepository10/plugins/Cinema4D”
Copy “Cinema4DBatch.py” to “DeadlineRepository10/plugins/Cinema4DBatch”
From here the Cinema 4D plugins will attempt to set the gpu affinity for Octane. Let me know if you run into any issues!
sorry, still uses all 4 GPUs.
I also disabled Use all GPUs inside C4D scene and submitted as 1 concurrent task 2 GPUs, and it is rendering with all 4 again.
Thanks for taking a look. From what we can tell over here, we’re following what they say to use. Unfortunately, it doesn’t look like they’ve added support for the -help flag, so we can’t see if this format is actually what they expect.
I’ll post or send a message asking about them this.
Would it be possible for you to also do a test render with Cinema4D non-batch? I expect the results to be the same, but I’d definitely appreciate having that datapoint available.
It is 3.07
Sorry was cleaning up deadline tasks and remove d this one but will add it again a bit later and submit log here. no problem.
Just have to clean active tasks a bit
What I’ve found is that the Octane command-line flags for C4D (ie. exporting orbx files) don’t appear to work as expected with the commandline.exe executable or with the -nogui option. I’ve brought this up with the Octane developers but there doesn’t appear to be movement on the issue.
Can you set Cinema4D.exe as the executable in the plugin configuration and see if that works for gpu affinity? I believe it’ll spawn a UI, but confirmation would be good to have.