AWS Thinkbox Discussion Forums

Deadline and Corona

Hi Everyone,

I’m sure we aren’t the only ones using deadline with corona, so was hoping to get some help in setting deadline monitor up.

(we, being www.the-boundary.com )

For animations we normally submit jobs with a pass limit, which works well with deadline. When viewing the monitor, you can easily check progress and see what pass limit was set (eg pass 15/75)

For still images we generally set a noise threshold of roughly 3.0 instead of a pass limit. Should it not be possible to set deadline up so that you can see what the target noise threshold is, and also what noise threshold it is currently at?

I was thinking we could use an ‘extra info’ column to display the target noise threshold, and then ideally the render status would display the current threshold.

Can anyone help??

thanks in advance

Peter

Hey Peter! Dwight and I were just discussing this actually. :slight_smile:

It might be possible, but how we do it would depends on when you would expect that information to change and what application you’re running your Corona render through.

We could make an OnJobSubmitted event that set the extra info when the job is created, and then use an OnJobStarted event to update it if you changed the job and re-queued it. There would also need to be data passed from the submitter, so it may make sense to just populate the extrainfo keys in there.

It doesn’t look like we have the noise threshold exposed to the plugin options for Corona standalone, so it’s not editable after the submission which makes thing somewhat easier I suppose. We do support editing the render time though.

Does anyone know how to pull the noise threshold from the Corona API? Also, is this Corona standalone or are the jobs running through Max, Maya, etc?

We are using 3dsmax. I think there was some info about this on the corona forum, will try and dig it out for you.

Thanks,

Peter

Ondra (Mr Corona) pointed me here: corona-renderer.com/doc/

Hi Edwin and Dwight,

Glad you are taking my request seriously, I’m more than happy to help test things or speak to Ondra to get more info on how corona works and what info you can get from it.

thanks

Peter

I try to take every request seriously. It’s somewhat more difficult to make time to implement the requests however. :slight_smile:

This is a customization though, so it won’t ship inside of Deadline and the dev team is likely not going to be implementing this for us.

The only thing I was able to find in the MaxScript API for noise was this:

 Estimated noise amount in the picture, in percents. Returns 0 if no estimate is available. (Corona 1.7+)

Which seems to just be stats from “the currently active render or last render” so how can we get the noise setting, and when do you expect it to update?

Hi Edwin,

The most important part for me would be to display the target noise threshold somewhere in monitor. I can live without the current noise threshold (although it would be nice). At the moment to only way to see what the target noise threshold is is to open up the .max file in auxiliary files.

I was hoping this would be a relatively simple thing, like adding a few lines of code to the submitter script to make the target noise threshold show up in one of the extra info slots?

There was a forum post on here about getting the render width and height and doing the same with that info so I assumed it should be possible.

In your post, when you say ‘how can we get the noise setting, and when do you expect it to update’ I’m not entirely sure what you mean, but if there is a more specific question I can pass on to the Corona team I would be happy to do so.

thanks!

Peter

Well, just like the real world where there is information you can freely read and information that is secret, and without knowing how to get the information (or if Corona keeps it a secret) from MaxScript there isn’t much plumbing we can do. Once we have the information the only challenging part in programming usually becomes passing the data around. Sometimes the existing design makes it hard to carry the data where it needs to go. Like a couch being brought up a staircase that is too narrow. You can knock down a wall or cut a hole in the ceiling to get it done, but is it worth it? Lovely programming problems. :smiley:

I think the ideal would be to have the Corona guys provide a MaxScript example of printing that data to the MaxScript listener. I think I could take it from there.

Does this help Edwin? from a helpful contributor on the corona forum:

That’s exactly what we needed!

Now to ask the experts how I could put that into the submission parameters… I’ve left the SMTD submission functions to the professionals all this time, but it should be pretty straightforward.

great! let me know if you want me to test anything

Peter

Ok, I am not a Corona specialist (in fact I have never installed it), but I consider myself fairly good at MAXScript, so let me try to clarify a few things…

First of all, SMTD dumps ALL Corona properties to the Job file on submission. Even the ones Deadline might not know about, or anything new that Ondra might have added in a newer build. So simply opening a Job’s properties and looking at the “Submission Params” tab > Plugin Info Parameters pane (right side) should display properties prefixed with “corona_” and then the name of the MAXScript property. Note that the list is already sorted alphabetically.

Second, to make all these properties editable, Deadline defines a 3dsmax.options file in the Repository\plugins\3dsmax folder. In it, any property listed in the Plugin Info file can be exposed via the “3dsmax Settings” tab of the Job Properties dialog.

It appears that the name of the Target Noise property at the time when we exposed Corona was “adaptivity_targetError”

[corona_adaptivity_targetError] Type=float Minimum=0 Maximum=1000 DecimalPlaces=3 Label=Noise level limit Category=Corona : General Settings : Progressive rendering limits CategoryOrder=1230 Required=false DisableIfBlank=true Index=60 Description=<html><head/><body><p>Sets the target error (noise level) at which rendering stops.<br><br>Use this option to render until a wanted image quality is reached (with no guarantee of processing time needed).<br><br>Set to 0 to disable the limit and render until either time or pass limit is reached, or the render is manually stopped.<br><br>Note: Only available when adaptivity is used (it is on by default).</p></body></html>

I am not sure if this property does the same as the one you listed - can you confirm whether it is an alias of the same value, a different feature, or some old retired property that has nothing to do with what you are asking about?

Of course you could easily add a new entry to the 3dsmax.options that has the name of the property you want to show/edit. The property must also be handled in customize.ms which reads the edited values and assigns them back to the current renderer.

This of course does not end up showing the info in the Monitor’s Job panel, just in the Job Properties, so some extra clicks are required. Stuffing that value into a custom info column would be possible, but I am reluctant to hard-code it into SMTD as it could conflict with what other customers are using those extra columns for. So I would like to think of a new more general feature of SMTD that would allow anyone to stuff any data into the Custom Info fields. Then you could use that feature to enable the behavior you want without affecting any other Deadline customers outside of your company…

thanks Bobo, this is all a bit over my head so I’ll need to pass it on to the corona brainboxes.

I just tested vray with a progressive render to compare it with corona. One difference is that you get a nice progress bar in deadline monitor that visually shows progress of the still render… that’s nice, would it be difficult to have the same with corona? In general though, when using a noise threshold as the thing that determines when your render ends, that info would be nice to have displayed somewhere.

When you set a pass limit with corona, deadline displays for example 56/100 - so you know how far it has got and what the user has set the desired pass limit to. I am just looking for a way to do a similar thing with a noise threshold.

The same could equally apply to vray if you set a very high max subdivs limit, no time limit, but set a desired noise threshold.

Check out the “Task Render Status” column in “Slaves” panel, as this will report the pass count/noise or whatever else, that is typically shown as the Render Scene Dialog progress Stdout message, purely as an un-formatted ‘string’ message.

In terms of scraping that above render progress message but when the render progress is based on noise/pass limit, then we would have to add direct support for this in our Lightning dll plugin. Is this what you need or will just the above “Task Render Status” column suffice? We would need to add direct support for “noise” progress separately for both Corona and V-Ray and any other renderer if we were to do this.

Hi Mike,

The task render status doesn’t report the current noise or target noise. It says 'Frame 0 - Pass 34 (elapsed: 0:31:00) - 15%

I think the % number above is how far it is through the current pass, so its not really useful to me.

Bobo, thanks for the explanation, being able to get to “corona_adaptivity_targetError=3%” in the Plugin Info Parameters is great, and saves having to open the max file. What I’d like to do now is have that info displayed in the tasks panel like attached. Is that what you are saying is problematic?

Yes, your right Peter. I did some tests with Corona 1.7 hotfix 3 and indeed by default, only the pass count, current pass and % progress is pushed to StdOut string during rendering, which is what we scrap and display in either “Render Status” (Tasks Panel) or “Task Render Status” (Slaves Panel).

I’m intrigued by the previous post you showed a snippet of “max.log” which shows the noise level being printed out to the max.log file. How was this achieved?

I can only find settings to control the Corona VFB Frame-Stamp and VFB title text in the Corona settings in the 3ds Max GUI. My “max.log” looks like this when Corona is rendering in GUI or Network render mode:

2018/03/21 10:41:42 INF: [04056] [05916] CORONA: Corona is up and running. Corona version: 1.7 (hotfix 3), netrender mode: off, slave mode: off, quiet mode: off, Max gamma (display/input/output): 2.2/2.2/2.2 2018/03/21 10:44:09 INF: [04056] [05916] CORONA : Parsing scene 2018/03/21 10:44:09 INF: [04056] [05916] CORONA : Calculating displacement 2018/03/21 10:44:09 INF: [04056] [05916] CORONA : Preparing geometry 2018/03/21 10:44:09 INF: [04056] [05916] CORONA : Preparing lights 2018/03/21 10:44:09 INF: [04056] [05916] CORONA : Computing sec. GI 2018/03/21 10:44:12 INF: [04056] [05916] CORONA : Rendering initial pass 2018/03/21 10:44:13 INF: [04056] [05916] CORONA : Rendering pass 2 2018/03/21 10:44:15 INF: [04056] [05916] CORONA : Rendering pass 3 2018/03/21 10:44:16 INF: [04056] [05916] CORONA : Rendering pass 4 2018/03/21 10:44:18 INF: [04056] [05916] CORONA : Rendering pass 5 2018/03/21 10:44:19 INF: [04056] [05916] CORONA : Rendering pass 6 ... 2018/03/21 10:44:59 INF: [04056] [05916] CORONA : Rendering pass 24 2018/03/21 10:45:01 INF: [04056] [05916] CORONA : Rendering pass 25 2018/03/21 10:45:02 INF: [04056] [05916] CORONA : Cleaning up 2018/03/21 12:52:28 DBG: [04056] [05916] Stop network

whereas you posted this:

2018/03/15 21:58:55 DBG: [67044] [95212] * Starting custom logger loop. 2018/03/15 21:58:55 INF: [67044] [95212] CORONA : Parsing scene 2018/03/15 21:58:55 INF: [67044] [95212] CORONA : Calculating displacement 2018/03/15 21:58:55 INF: [67044] [95212] CORONA : Preparing geometry 2018/03/15 21:58:55 INF: [67044] [95212] CORONA : Preparing lights 2018/03/15 21:58:55 INF: [67044] [95212] CORONA : Computing sec. GI 2018/03/15 21:58:57 INF: [67044] [95212] CORONA : Pass 1/500 2018/03/15 21:59:00 INF: [67044] [95212] CORONA : Pass 2/500 2018/03/15 21:59:04 INF: [67044] [95212] CORONA : Pass 3/500 2018/03/15 21:59:05 INF: [67044] [98816] CORONA : Passes: 2/500 | Noise: 0.00(1.5) | Time: 00:00:07/01:00:00 | ETA: not yet ... 2018/03/15 22:00:40 INF: [67044] [98816] CORONA : Passes: 32/500 | Noise: 1.52(1.5) | Time: 00:01:43/01:00:00 | ETA: not yet 2018/03/15 22:00:43 INF: [67044] [95212] CORONA : Pass 34/500 2018/03/15 22:00:45 INF: [67044] [98816] CORONA : Passes: 33/500 | Noise: 1.52(1.5) | Time: 00:01:48/01:00:00 | ETA: not yet 2018/03/15 22:00:46 INF: [67044] [95212] CORONA : Pass 35/500 2018/03/15 22:00:49 INF: [67044] [95212] CORONA : Cleaning up 2018/03/15 22:00:49 DBG: [67044] [95212] * Terminating custom logger loop.

The “custom logger loop” makes me think this is only possible in a Corona internal dev build/debug mode.

@Peter - please could you clarify. Are you asking for a static (not changing during rendering) value which is present via the MXS renderer props of the job as per Bobo’s previous reply OR are you asking for the dynamically changing “Noise Level” value to be re-captured and displayed in the Deadline Monitor when the job is rendering?

Hi Mike,

re: all the complex stuff, I’m just relaying info from here: corona-renderer.com/forum/index … ic=19595.0 as I have no idea about scripting

and to clarify, I am asking for a static display of what the user set the target noise threshold to when they submitted the job

IF, in the future it would be possible to get a ‘live’ display of the current noise threshold that would be nice, but that can wait till deadline 11…

Adding the Static Display to an Extra Info column is already possible (although not entirely obvious).

The Extra Info column already supports a system of $tokens that can be replaced dynamically with any content queried from the scene. The Tokens themselves are defined at Repository (company) level via an INI file stored under \submission\3dsMax\Main\SubmitMaxToDeadline_ExtraInfoFormats.ini

Inside this file, you will find things like

$scene=(getfilenamefile(maxfilename)) $date=((filterstring (localtime) " ")[1]) $deadlineusername=(SMTDFunctions.GetDeadlineUser()) $username=(sysInfo.username) $camera=(local theCam = viewport.getCamera() if (isValidNode theCam) then theCam.name else "") $outputfilename=(if (rendOutputFilename != "") then (filenameFromPath rendOutputFilename) else "") $outputfile=(if (rendOutputFilename != "") then (getFilenameFile rendOutputFilename) else "") $outputtype=(if (rendOutputFilename != "") then (getFilenameType rendOutputFilename) else "") $maxversion=(((maxVersion())[1]/1000) as string) ...
and many more. For example, if you wanted the name of the MAX scene file to show up in ExtraInfo0, you could just type in $scene in that field in the SMTD UI, and your Monitor would show the name in the ExtraInfo0 column!

So you should be able to add a new line to the INI file that says

$coronanoisetarget=(if (isProperty renderers.current #target_image_noise_level__error) then ("Corona Noise Target: "+ renderers.current.target_image_noise_level__error as string)  else "" )

Save the INI file, launch SMTD and type in

$coronanoisetarget

in any of the Extra Info fields under the [Misc] tab, Exta Info rollout fields. Let’s use Extra Info 9 for our example.

If you submit a job now, the 9th Extra Info column in the Monitor will show the value of the Noise Target, or nothing of the job was not a Corona job.

So far, so good. But you don’t want to rely on your artists to populate that field manually when submitting jobs, so how do we enforce that token on every submission? We simply have to change a few more INI files in the same Repository folder to instruct SMTD to always have that value in the Extra Info 9 field:

  • Locate the file “…\submission\3dsmax\Main\SubmitMaxToDeadline_Defaults.ini” and open it for editing
  • Scroll to the very bottom and find the line for ExtraInfo9
  • Change it to
ExtraInfo9=$coronanoisetarget
  • Save the file and close it.
    At this point, we have supplied a default value for the desired SMTD property. Next, we need to ensure that default value is used globally (as opposed to being overwritten by local sticky settings, or MAX file settings).

  • Locate the file “…\submission\3dsmax\Main\SubmitMaxToDeadline_StickySettings.ini” and open it for editing.

  • Scroll to the very bottom and make sure you have ExtraInfo9=false (that’s the default anyway).

  • Save if needed.

  • Locate the file “…\submission\3dsmax\Main\SubmitMaxToDeadline_ExcludeFromSceneStorage.ini” and open for editing.

  • Scroll to the very bottom and locate the ExtraInfo9 line.

  • Change it to

ExtraInfo9=true
  • Save the file.
    With this, we have instructed SMTD v10 to ignore the ExtraInfo9 value stored in MAX scene files previously submitted to Deadline. Thus, opening a scene from a month ago would not override the global default we just defined with “” stored in the MAX scene.

From now on, every artist who opens SMTD and looks under the Extra Info rollout will find the “$coronanoisetarget” string automatically assigned for every new job, and your Deadline Monitor will have that extra column with the value you wanted. If the job does not use Corona, the field will remain empty. If you define something like that for V-Ray, you could put both tokens in the same Extra Info field, but only the relevant one will show up, so you can reuse the filed for multiple renderers!

You can do this with any other submission time properties you might want to expose.

As for the dynamic progress support, we will add it to the Wishlist and see what happens… :smiley:

Absolutely fantastic Bobo, thanks for making it easy for even an idiot like me to understand. Works perfectly.

Privacy | Site terms | Cookie preferences