AWS Thinkbox Discussion Forums

trying to use the new 3dsmaxbatch.exe

3dsMax 2018.4 has new 3dsmaxbatch.exe.
I think I can utilize commandline plugin to do what I want.
It seems it would not be that hard to even modify commandline plugin and make a new 3dsmaxbatch plugin.

One problem is… I need to load Lightning plugin to update the progress and log messages.
Would it be enough if I just include Lightning plugin in plugin.ini and launch 3dsMax?
Or… do I need to do something special?

When I reviewed the new 3dsmaxbatch executable, I could not see any benefit of using it over our current offering of 3dsCmd and 3dsmax plugins in Deadline. I’m not sure we would ever add support for this new batch exe thing as it doesn’t help our customers. Do you have a use case for this new executable? Would love to understand your requirements here.

It is faster to launch and allow to save anything(idk 3dscmd allow this).
Also I have control over log and pass argument from commandline instead of work around with persistent global.

I’m not asking to support 3dsmaxbatch.exe.
I’m asking for help to do by myself.

So… the main question is…
If I load Lightning plugin, all good?

ok. I don’t see any need for Lightning to be used in that case. In fact, I wouldn’t even bother using it here.

Log messages and progress can be updated using the std Deadline py tools via our API:

DeadlinePlugin.LogInfo( string message )

docs.thinkboxsoftware.com/produ … 498961151d

there is also: LogWarning, LogStdout and std built-in Python print() and logger

for progress, you can use std DL StdOutHandlers and RegEx parsers to capture any program generated stdout/err

and report progress per task via:

DeadlinePlugin.SetProgress( float )

docs.thinkboxsoftware.com/produ … 6011018760

Also, don’t forget to use:

DeadlinePlugin.SetStatusMessage( string )

if you want to set the Slave’s “Task Render Status” column in Slaves/Tasks Panel in Monitor.

You should be able to build out an entire custom 3dsmaxbatch plugin workflow based on something like the existing CommandLine plugin we ship with.

3dsCmd does not allow you to “save” anything.

If others find this app in 3dsMax useful, I wouldn’t be adverse to looking at adding support directly into Deadline in the future.

Thanks.
Let me try.

Yeah. 3dsmaxbatch.exe allow you to save anything which means Autodesk is giving out Fluid sim lic for free.

3dsmaxbatch allows you to run some 3ds Max compute operations (simulation, caching, possibly rendering?) for free on AWS thanks to “Cloud Rights” - it offsets the need for MaxIO UBL for customers on support. I am not sure if it is enough, but I do believe we should look into supporting it.

knowledge.autodesk.com/support/ … ights.html

Yes, you can render, too.
I don’t think It has any technical limitation.

The launch speed is pretty good. 2019 is even better.
At home, it start max in 11sec.

So… progress amount parsing is not working.

I have output like this.

The progress bar is not doing anything.

To help here, I would need to see your py code to ensure you are using the StdOutHandler function correctly for the process you are monitoring.

I used CommandlinePlugin.

Do you have this all in place within the class that spawns the process?

[code] def InitializeProcess( self ):
self.StdoutHandling = True
self.AddStdoutHandlerCallback( “.Progress: (\d+)%.” ).HandleCallback += self.HandleProgress

def HandleProgress( self ):
    progress = float( self.GetRegexMatch(1) )
    self.SetProgress( progress )[/code]

if so, what command are you using to spawn the process in the plugin?

We just renamed CommandlinePlugi to Fuse3dsMaxBatch.

=======================================================
Log

2018-04-23 18:20:46: 0: Plugin will be reloaded because a new job has been loaded.
2018-04-23 18:20:46: 0: Loading Job’s Plugin timeout is Disabled
2018-04-23 18:20:48: 0: Loaded plugin Fuse3dsMaxBatch
2018-04-23 18:20:48: 0: Executing plugin command of type ‘Sync Files for Job’
2018-04-23 18:20:48: 0: All job files are already synchronized
2018-04-23 18:20:48: 0: Synchronizing Plugin Fuse3dsMaxBatch from \fla-fs\deadline\DeadlineRepository9\custom\plugins\Fuse3dsMaxBatch took: 0 seconds
2018-04-23 18:20:48: 0: Done executing plugin command of type ‘Sync Files for Job’
2018-04-23 18:20:48: 0: Executing plugin command of type ‘Initialize Plugin’
2018-04-23 18:20:49: 0: INFO: Executing plugin script ‘C:\Users\render.FUSEFX\AppData\Local\Thinkbox\Deadline9\slave\fla-rnt293\plugins\5ade863d2d3cb51330d28e42\Fuse3dsMaxBatch.py’
2018-04-23 18:20:49: 0: INFO: About: Fuse 3ds Max Batch Runner
2018-04-23 18:20:49: 0: INFO: Render Job As User disabled, running as current user ‘render’
2018-04-23 18:20:49: 0: INFO: The job’s environment will be merged with the current environment before rendering
2018-04-23 18:20:49: 0: Done executing plugin command of type ‘Initialize Plugin’
2018-04-23 18:20:49: 0: Start Job timeout is disabled.
2018-04-23 18:20:49: 0: Task timeout is disabled.
2018-04-23 18:20:49: 0: Loaded job: 3dsMaxBatchTest (5ade863d2d3cb51330d28e42)
2018-04-23 18:20:49: 0: Executing plugin command of type ‘Start Job’
2018-04-23 18:20:49: 0: Done executing plugin command of type ‘Start Job’
2018-04-23 18:20:49: 0: Plugin rendering frame(s): 0
2018-04-23 18:20:49: 0: Executing plugin command of type ‘Render Task’
2018-04-23 18:20:49: 0: INFO: Executable: C:/Program Files/Autodesk/3ds Max 2018/3dsmaxbatch.exe
2018-04-23 18:20:49: 0: INFO: Arguments: “[path to script]/libMaxbatch.ms” -mxsString gridname:“csTest” -v 5 -dateFormat “” -timeFormat “” -dm true -log “” -sceneFile “”
2018-04-23 18:20:49: 0: INFO: 3dsMaxBatch Task Started 9
2018-04-23 18:20:49: 0: INFO: Invoking: Run Process
2018-04-23 18:20:50: 0: STDOUT: 4/23/2018 18:20:50 PM; Specified option dateFormat:
2018-04-23 18:20:50: 0: STDOUT:
2018-04-23 18:20:50: 0: STDOUT: 4/23/2018 18:20:50 PM; Specified option timeFormat:
2018-04-23 18:20:50: 0: STDOUT:
2018-04-23 18:20:50: 0: STDOUT: 4/23/2018 18:20:50 PM; Specified option script: “[path to script]s/libMaxbatch.ms
2018-04-23 18:20:50: 0: STDOUT:
2018-04-23 18:20:50: 0: STDOUT: 4/23/2018 18:20:50 PM; Specified option sceneFile:
2018-04-23 18:20:50: 0: STDOUT:
2018-04-23 18:20:50: 0: STDOUT: 4/23/2018 18:20:50 PM; Specified option dm: 1
2018-04-23 18:20:50: 0: STDOUT:
2018-04-23 18:20:50: 0: STDOUT: 4/23/2018 18:20:50 PM; Specified option log:
2018-04-23 18:20:50: 0: STDOUT:
2018-04-23 18:20:50: 0: STDOUT: 4/23/2018 18:20:50 PM; Specified option mxsString: { “gridname:csTest” }
2018-04-23 18:20:50: 0: STDOUT:
2018-04-23 18:20:50: 0: STDOUT: 4/23/2018 18:20:50 PM; 3ds Max Install Location: C:\Program Files\Autodesk\3ds Max 2018
2018-04-23 18:20:50: 0: STDOUT:
2018-04-23 18:20:51: 0: STDOUT: 4/23/2018 18:20:50 PM; 3ds Max Executable: 3dsmax.exe
2018-04-23 18:20:51: 0: STDOUT:
2018-04-23 18:20:51: 0: STDOUT: 4/23/2018 18:20:50 PM; Secure Mode: ‘OFF’
2018-04-23 18:20:51: 0: STDOUT:
2018-04-23 18:20:51: 0: STDOUT: 4/23/2018 18:20:50 PM; Dialog Monitor: On
2018-04-23 18:20:51: 0: STDOUT:
2018-04-23 18:20:51: 0: STDOUT: 4/23/2018 18:20:50 PM; Script command: " -mxs “((maxOps.mxsCmdLineArgs = dictionary #name ‘gridname’:“csTest”); filein @“S:\outfit\developers\changsooeun\FFXPipeline\FFX_3d\max\fusetools\libMaxbatch.ms”)””
2018-04-23 18:20:51: 0: STDOUT:
2018-04-23 18:20:51: 0: STDOUT: 4/23/2018 18:20:50 PM; Product version: 3ds Max 2018.4 Update (20.4.0.4254)
2018-04-23 18:20:51: 0: STDOUT:
2018-04-23 18:20:51: 0: STDOUT: 4/23/2018 18:20:50 PM; Data collection and use is ‘ON’. Change your participation anytime in the Help menu of 3ds Max.
2018-04-23 18:20:51: 0: STDOUT:
2018-04-23 18:21:18: 0: STDOUT: 4/23/2018 18:21:18 PM; START - csTest
2018-04-23 18:21:18: 0: STDOUT:
2018-04-23 18:21:18: 0: STDOUT: 4/23/2018 18:21:18 PM; Progress: 0%
2018-04-23 18:21:18: 0: STDOUT:
2018-04-23 18:21:18: 0: STDOUT: 4/23/2018 18:21:18 PM; Progress: 1%
2018-04-23 18:21:18: 0: STDOUT:
2018-04-23 18:21:19: 0: STDOUT: 4/23/2018 18:21:18 PM; Progress: 2%
2018-04-23 18:21:19: 0: STDOUT:
2018-04-23 18:21:19: 0: STDOUT: 4/23/2018 18:21:19 PM; Progress: 3%
2018-04-23 18:21:19: 0: STDOUT:
2018-04-23 18:21:19: 0: STDOUT: 4/23/2018 18:21:19 PM; Progress: 4%
2018-04-23 18:21:19: 0: STDOUT:
2018-04-23 18:21:19: 0: STDOUT: 4/23/2018 18:21:19 PM; Progress: 5%
2018-04-23 18:21:19: 0: STDOUT:
2018-04-23 18:21:19: 0: STDOUT: 4/23/2018 18:21:19 PM; Progress: 6%
2018-04-23 18:21:20: 0: STDOUT:
2018-04-23 18:21:20: 0: STDOUT: 4/23/2018 18:21:20 PM; Progress: 7%
2018-04-23 18:21:20: 0: STDOUT:
2018-04-23 18:21:20: 0: STDOUT: 4/23/2018 18:21:20 PM; Progress: 8%
2018-04-23 18:21:20: 0: STDOUT:
2018-04-23 18:21:20: 0: STDOUT: 4/23/2018 18:21:20 PM; Progress: 9%
2018-04-23 18:21:20: 0: STDOUT:
2018-04-23 18:21:20: 0: STDOUT: 4/23/2018 18:21:20 PM; Progress: 10%
2018-04-23 18:21:20: 0: STDOUT:
2018-04-23 18:21:20: 0: STDOUT: 4/23/2018 18:21:20 PM; Progress: 11%
2018-04-23 18:21:21: 0: STDOUT:
2018-04-23 18:21:21: 0: STDOUT: 4/23/2018 18:21:21 PM; Progress: 12%
2018-04-23 18:21:21: 0: STDOUT:
2018-04-23 18:21:21: 0: STDOUT: 4/23/2018 18:21:21 PM; Progress: 13%
2018-04-23 18:21:21: 0: STDOUT:
2018-04-23 18:21:21: 0: STDOUT: 4/23/2018 18:21:21 PM; Progress: 14%
2018-04-23 18:21:21: 0: STDOUT:
2018-04-23 18:21:21: 0: STDOUT: 4/23/2018 18:21:21 PM; Progress: 15%
2018-04-23 18:21:21: 0: STDOUT:
2018-04-23 18:21:21: 0: STDOUT: 4/23/2018 18:21:21 PM; Progress: 16%
2018-04-23 18:21:22: 0: STDOUT:
2018-04-23 18:21:22: 0: STDOUT: 4/23/2018 18:21:22 PM; Progress: 17%
2018-04-23 18:21:22: 0: STDOUT:
2018-04-23 18:21:22: 0: STDOUT: 4/23/2018 18:21:22 PM; Progress: 18%
2018-04-23 18:21:22: 0: STDOUT:
2018-04-23 18:21:22: 0: STDOUT: 4/23/2018 18:21:22 PM; Progress: 19%
2018-04-23 18:21:22: 0: STDOUT:
2018-04-23 18:21:22: 0: STDOUT: 4/23/2018 18:21:22 PM; Progress: 20%
2018-04-23 18:21:22: 0: STDOUT:
2018-04-23 18:21:22: 0: STDOUT: 4/23/2018 18:21:22 PM; Progress: 21%
2018-04-23 18:21:23: 0: STDOUT:
2018-04-23 18:21:23: 0: STDOUT: 4/23/2018 18:21:23 PM; Progress: 22%
2018-04-23 18:21:23: 0: STDOUT:
2018-04-23 18:21:23: 0: STDOUT: 4/23/2018 18:21:23 PM; Progress: 23%
2018-04-23 18:21:23: 0: STDOUT:
2018-04-23 18:21:23: 0: STDOUT: 4/23/2018 18:21:23 PM; Progress: 24%
2018-04-23 18:21:23: 0: STDOUT:
2018-04-23 18:21:23: 0: STDOUT: 4/23/2018 18:21:23 PM; Progress: 25%
2018-04-23 18:21:23: 0: STDOUT:
2018-04-23 18:21:24: 0: STDOUT: 4/23/2018 18:21:23 PM; Progress: 26%
2018-04-23 18:21:24: 0: STDOUT:
2018-04-23 18:21:24: 0: STDOUT: 4/23/2018 18:21:24 PM; Progress: 27%
2018-04-23 18:21:24: 0: STDOUT:
2018-04-23 18:21:24: 0: STDOUT: 4/23/2018 18:21:24 PM; Progress: 28%
2018-04-23 18:21:24: 0: STDOUT:
2018-04-23 18:21:24: 0: STDOUT: 4/23/2018 18:21:24 PM; Progress: 29%
2018-04-23 18:21:24: 0: STDOUT:
2018-04-23 18:21:24: 0: STDOUT: 4/23/2018 18:21:24 PM; Progress: 30%
2018-04-23 18:21:24: 0: STDOUT:
2018-04-23 18:21:25: 0: STDOUT: 4/23/2018 18:21:24 PM; Progress: 31%
2018-04-23 18:21:25: 0: STDOUT:
2018-04-23 18:21:25: 0: STDOUT: 4/23/2018 18:21:25 PM; Progress: 32%
2018-04-23 18:21:25: 0: STDOUT:
2018-04-23 18:21:25: 0: STDOUT: 4/23/2018 18:21:25 PM; Progress: 33%
2018-04-23 18:21:25: 0: STDOUT:
2018-04-23 18:21:25: 0: STDOUT: 4/23/2018 18:21:25 PM; Progress: 34%
2018-04-23 18:21:25: 0: STDOUT:
2018-04-23 18:21:25: 0: STDOUT: 4/23/2018 18:21:25 PM; Progress: 35%
2018-04-23 18:21:25: 0: STDOUT:
2018-04-23 18:21:26: 0: STDOUT: 4/23/2018 18:21:25 PM; Progress: 36%
2018-04-23 18:21:26: 0: STDOUT:
2018-04-23 18:21:26: 0: STDOUT: 4/23/2018 18:21:26 PM; Progress: 37%
2018-04-23 18:21:26: 0: STDOUT:
2018-04-23 18:21:26: 0: STDOUT: 4/23/2018 18:21:26 PM; Progress: 38%
2018-04-23 18:21:26: 0: STDOUT:
2018-04-23 18:21:26: 0: STDOUT: 4/23/2018 18:21:26 PM; Progress: 39%
2018-04-23 18:21:26: 0: STDOUT:
2018-04-23 18:21:26: 0: STDOUT: 4/23/2018 18:21:26 PM; Progress: 40%
2018-04-23 18:21:26: 0: STDOUT:
2018-04-23 18:21:27: 0: STDOUT: 4/23/2018 18:21:26 PM; Progress: 41%
2018-04-23 18:21:27: 0: STDOUT:
2018-04-23 18:21:27: 0: STDOUT: 4/23/2018 18:21:27 PM; Progress: 42%
2018-04-23 18:21:27: 0: STDOUT:
2018-04-23 18:21:27: 0: STDOUT: 4/23/2018 18:21:27 PM; Progress: 43%
2018-04-23 18:21:27: 0: STDOUT:
2018-04-23 18:21:27: 0: STDOUT: 4/23/2018 18:21:27 PM; Progress: 44%
2018-04-23 18:21:27: 0: STDOUT:
2018-04-23 18:21:27: 0: STDOUT: 4/23/2018 18:21:27 PM; Progress: 45%
2018-04-23 18:21:27: 0: STDOUT:
2018-04-23 18:21:28: 0: STDOUT: 4/23/2018 18:21:28 PM; Progress: 46%
2018-04-23 18:21:28: 0: STDOUT:
2018-04-23 18:21:28: 0: STDOUT: 4/23/2018 18:21:28 PM; Progress: 47%
2018-04-23 18:21:28: 0: STDOUT:
2018-04-23 18:21:28: 0: STDOUT: 4/23/2018 18:21:28 PM; Progress: 48%
2018-04-23 18:21:28: 0: STDOUT:
2018-04-23 18:21:28: 0: STDOUT: 4/23/2018 18:21:28 PM; Progress: 49%
2018-04-23 18:21:28: 0: STDOUT:
2018-04-23 18:21:28: 0: STDOUT: 4/23/2018 18:21:28 PM; Progress: 50%
2018-04-23 18:21:28: 0: STDOUT:
2018-04-23 18:21:29: 0: STDOUT: 4/23/2018 18:21:29 PM; Progress: 51%
2018-04-23 18:21:29: 0: STDOUT:
2018-04-23 18:21:29: 0: STDOUT: 4/23/2018 18:21:29 PM; Progress: 52%
2018-04-23 18:21:29: 0: STDOUT:
2018-04-23 18:21:29: 0: STDOUT: 4/23/2018 18:21:29 PM; Progress: 53%
2018-04-23 18:21:29: 0: STDOUT:
2018-04-23 18:21:29: 0: STDOUT: 4/23/2018 18:21:29 PM; Progress: 54%
2018-04-23 18:21:29: 0: STDOUT:
2018-04-23 18:21:29: 0: STDOUT: 4/23/2018 18:21:29 PM; Progress: 55%
2018-04-23 18:21:29: 0: STDOUT:
2018-04-23 18:21:30: 0: STDOUT: 4/23/2018 18:21:30 PM; Progress: 56%
2018-04-23 18:21:30: 0: STDOUT:
2018-04-23 18:21:30: 0: STDOUT: 4/23/2018 18:21:30 PM; Progress: 57%
2018-04-23 18:21:30: 0: STDOUT:
2018-04-23 18:21:30: 0: STDOUT: 4/23/2018 18:21:30 PM; Progress: 58%
2018-04-23 18:21:30: 0: STDOUT:
2018-04-23 18:21:30: 0: STDOUT: 4/23/2018 18:21:30 PM; Progress: 59%
2018-04-23 18:21:30: 0: STDOUT:
2018-04-23 18:21:30: 0: STDOUT: 4/23/2018 18:21:30 PM; Progress: 60%
2018-04-23 18:21:31: 0: STDOUT:
2018-04-23 18:21:31: 0: STDOUT: 4/23/2018 18:21:31 PM; Progress: 61%
2018-04-23 18:21:31: 0: STDOUT:
2018-04-23 18:21:31: 0: STDOUT: 4/23/2018 18:21:31 PM; Progress: 62%
2018-04-23 18:21:31: 0: STDOUT:
2018-04-23 18:21:31: 0: STDOUT: 4/23/2018 18:21:31 PM; Progress: 63%
2018-04-23 18:21:31: 0: STDOUT:
2018-04-23 18:21:31: 0: STDOUT: 4/23/2018 18:21:31 PM; Progress: 64%
2018-04-23 18:21:31: 0: STDOUT:
2018-04-23 18:21:32: 0: STDOUT: 4/23/2018 18:21:31 PM; Progress: 65%
2018-04-23 18:21:32: 0: STDOUT:
2018-04-23 18:21:32: 0: STDOUT: 4/23/2018 18:21:32 PM; Progress: 66%
2018-04-23 18:21:32: 0: STDOUT:
2018-04-23 18:21:32: 0: STDOUT: 4/23/2018 18:21:32 PM; Progress: 67%
2018-04-23 18:21:32: 0: STDOUT:
2018-04-23 18:21:32: 0: STDOUT: 4/23/2018 18:21:32 PM; Progress: 68%
2018-04-23 18:21:32: 0: STDOUT:
2018-04-23 18:21:32: 0: STDOUT: 4/23/2018 18:21:32 PM; Progress: 69%
2018-04-23 18:21:32: 0: STDOUT:
2018-04-23 18:21:32: 0: STDOUT: 4/23/2018 18:21:32 PM; Progress: 70%
2018-04-23 18:21:33: 0: STDOUT:
2018-04-23 18:21:33: 0: STDOUT: 4/23/2018 18:21:33 PM; Progress: 71%
2018-04-23 18:21:33: 0: STDOUT:
2018-04-23 18:21:33: 0: STDOUT: 4/23/2018 18:21:33 PM; Progress: 72%
2018-04-23 18:21:33: 0: STDOUT:
2018-04-23 18:21:33: 0: STDOUT: 4/23/2018 18:21:33 PM; Progress: 73%
2018-04-23 18:21:33: 0: STDOUT:
2018-04-23 18:21:33: 0: STDOUT: 4/23/2018 18:21:33 PM; Progress: 74%
2018-04-23 18:21:33: 0: STDOUT:
2018-04-23 18:21:34: 0: STDOUT: 4/23/2018 18:21:33 PM; Progress: 75%
2018-04-23 18:21:34: 0: STDOUT:
2018-04-23 18:21:34: 0: STDOUT: 4/23/2018 18:21:34 PM; Progress: 76%
2018-04-23 18:21:34: 0: STDOUT:
2018-04-23 18:21:34: 0: STDOUT: 4/23/2018 18:21:34 PM; Progress: 77%
2018-04-23 18:21:34: 0: STDOUT:
2018-04-23 18:21:34: 0: STDOUT: 4/23/2018 18:21:34 PM; Progress: 78%
2018-04-23 18:21:34: 0: STDOUT:
2018-04-23 18:21:34: 0: STDOUT: 4/23/2018 18:21:34 PM; Progress: 79%
2018-04-23 18:21:34: 0: STDOUT:
2018-04-23 18:21:35: 0: STDOUT: 4/23/2018 18:21:34 PM; Progress: 80%
2018-04-23 18:21:35: 0: STDOUT:
2018-04-23 18:21:35: 0: STDOUT: 4/23/2018 18:21:35 PM; Progress: 81%
2018-04-23 18:21:35: 0: STDOUT:
2018-04-23 18:21:35: 0: STDOUT: 4/23/2018 18:21:35 PM; Progress: 82%
2018-04-23 18:21:35: 0: STDOUT:
2018-04-23 18:21:35: 0: STDOUT: 4/23/2018 18:21:35 PM; Progress: 83%
2018-04-23 18:21:35: 0: STDOUT:
2018-04-23 18:21:35: 0: STDOUT: 4/23/2018 18:21:35 PM; Progress: 84%
2018-04-23 18:21:35: 0: STDOUT:
2018-04-23 18:21:36: 0: STDOUT: 4/23/2018 18:21:35 PM; Progress: 85%
2018-04-23 18:21:36: 0: STDOUT:
2018-04-23 18:21:36: 0: STDOUT: 4/23/2018 18:21:36 PM; Progress: 86%
2018-04-23 18:21:36: 0: STDOUT:
2018-04-23 18:21:36: 0: STDOUT: 4/23/2018 18:21:36 PM; Progress: 87%
2018-04-23 18:21:36: 0: STDOUT:
2018-04-23 18:21:36: 0: STDOUT: 4/23/2018 18:21:36 PM; Progress: 88%
2018-04-23 18:21:36: 0: STDOUT:
2018-04-23 18:21:36: 0: STDOUT: 4/23/2018 18:21:36 PM; Progress: 89%
2018-04-23 18:21:36: 0: STDOUT:
2018-04-23 18:21:37: 0: STDOUT: 4/23/2018 18:21:37 PM; Progress: 90%
2018-04-23 18:21:37: 0: STDOUT:
2018-04-23 18:21:37: 0: STDOUT: 4/23/2018 18:21:37 PM; Progress: 91%
2018-04-23 18:21:37: 0: STDOUT:
2018-04-23 18:21:37: 0: STDOUT: 4/23/2018 18:21:37 PM; Progress: 92%
2018-04-23 18:21:37: 0: STDOUT:
2018-04-23 18:21:37: 0: STDOUT: 4/23/2018 18:21:37 PM; Progress: 93%
2018-04-23 18:21:37: 0: STDOUT:
2018-04-23 18:21:37: 0: STDOUT: 4/23/2018 18:21:37 PM; Progress: 94%
2018-04-23 18:21:37: 0: STDOUT:
2018-04-23 18:21:38: 0: STDOUT: 4/23/2018 18:21:38 PM; Progress: 95%
2018-04-23 18:21:38: 0: STDOUT:
2018-04-23 18:21:38: 0: STDOUT: 4/23/2018 18:21:38 PM; Progress: 96%
2018-04-23 18:21:38: 0: STDOUT:
2018-04-23 18:21:38: 0: STDOUT: 4/23/2018 18:21:38 PM; Progress: 97%
2018-04-23 18:21:38: 0: STDOUT:
2018-04-23 18:21:38: 0: STDOUT: 4/23/2018 18:21:38 PM; Progress: 98%
2018-04-23 18:21:38: 0: STDOUT:
2018-04-23 18:21:38: 0: STDOUT: 4/23/2018 18:21:38 PM; Progress: 99%
2018-04-23 18:21:39: 0: STDOUT:
2018-04-23 18:21:39: 0: STDOUT: 4/23/2018 18:21:39 PM; Progress: 100%
2018-04-23 18:21:39: 0: STDOUT:
2018-04-23 18:21:40: 0: STDOUT: 4/23/2018 18:21:40 PM; Done
2018-04-23 18:21:40: 0: STDOUT:
2018-04-23 18:21:41: 0: STDOUT: 4/23/2018 18:21:40 PM; [V-Ray] Maximum memory usage for texman: 0.00 MB
2018-04-23 18:21:41: 0: STDOUT:
2018-04-23 18:21:41: 0: STDOUT: 4/23/2018 18:21:40 PM; Task Completed Successfully
2018-04-23 18:21:41: 0: STDOUT:
2018-04-23 18:21:41: 0: STDOUT: 4/23/2018 18:21:40 PM; 3ds Max Shutting Down
2018-04-23 18:21:41: 0: STDOUT:
2018-04-23 18:21:48: 0: STDOUT: 4/23/2018 18:21:48 PM; 3ds Max Exit Code = 0
2018-04-23 18:21:48: 0: STDOUT:
2018-04-23 18:21:48: 0: STDOUT:
2018-04-23 18:21:48: 0: INFO: Process returned: 0
2018-04-23 18:21:48: 0: Done executing plugin command of type ‘Render Task’
2018-04-23 18:21:48: 0: Render time for frame(s): 59.331 s
2018-04-23 18:21:48: 0: Total time for task: 1.156 m
2018-04-23 18:21:49: 0: Saving task log…

=======================================================
Details

Date: 04/23/2018 18:21:49
Frames: 0
Job Submit Date: 04/23/2018 18:19:57
Job User: changsooeun
Average RAM Usage: 781508288 (1%)
Peak RAM Usage: 1212895232 (1%)
Average CPU Usage: 1%
Peak CPU Usage: 1%
Used CPU Clocks (x10^6 cycles): 53713
Total CPU Clocks (x10^6 cycles): 5371248

=======================================================
Slave Information

Slave Name: FLA-RNT293
Version: v9.0.6.1 Release (96b611826)
Operating System: Windows 10 Pro
Running As Service: No
Machine User: render
IP Address: 10.42.161.238
MAC Address: 0C:C4:7A:E0:F6:46
CPU Architecture: x64
CPUs: 56
CPU Usage: 0%
Memory Usage: 8.0 GB / 255.9 GB (3%)
Free Disk Space: 571.643 GB
Video Card: Microsoft Basic Display Adapter

ok, thanks for confirming. I wonder if this is simply an encoding issue as we have the same issue with our 3dsCmd plugin. Can you try forcing the encoding in the managed process depending on the version of 3dsMax you are using?, something like this:

# Newer versions of 3dsCmd use UTF-16-LE for stdout/stderr encoding. if self.Version >= 2016: self.CmdProcess.StdOutEncoding = "utf-16"

For reference: docs.thinkboxsoftware.com/produ … 23b29d4efc

EDIT: Just noticed your version of Deadline according to your log is 9.0.6 and we added this new API call in 9.0.7. Latest Deadline version is 10.0.14.1

So… I need to force cmd output as “utf-16”?
It is win10. Should it be already “utf-16”?

Or… do I need to tell deadline it is “utf-16”.

I’m using RunProcess.
How can I tell RunProcess it is “utf-16”?
Can I make custom code with subprocess module?

OK, couple of things happening here, which are stopping this from working for you.

Autodesk changed the encoding type of StdOut/Err coming from the 3dsmaxcmd.exe process in 3ds Max 2016 and onwards. Autodesk made this change. You can see a few patterns if you compare it to older StdOut/Err being generated by 3dsmaxcmd.exe from < 2016. Firstly, there is now a BLANK line between each string message and the Deadline StdOutHandlers no longer were catching or recognising the strings, as we were always expecting utf-8, which pretty much everyone else uses in their cout.

To resolve this issue, sometime ago we added in Deadline 9.0.7 a new setting in our FranticX class:
docs.thinkboxsoftware.com/produ … 23b29d4efc

ManagedProcess.StdOutEncoding

In the case of a vanilla copy of the CommandLine.py plugin file, you would add the above line in the “InitializeProcess()” function of the ManagedProcess you invoke, like this:

def InitializeProcess( self ): self.PluginType = PluginType.Advanced self.StdoutHandling = True self.StdOutEncoding = "utf-16"

Now for your second issue. Deadline’s “RunProcess” is an unmanaged process (fire and forget missile), you really want a Tomahawk “guided” missle, which comes in the form of a “ManagedProcess”. StdOut/Err is NOT captured in an unmanaged process, hence you stdout handler not working. We make a comment about this in our CommandLine.py code at line: #61 (Deadline 10.0.14)

# StdOut/Err will NOT be captured here as unmanaged process

So, the way to solve this 2nd issue is to create another class (or re-use the class in the CommandLine plugin), remove the parts which force it to be invoked through whatever SHELL a user wants, instead target your RenderExecutable and then invoke it via line: #66, as we do already:

self.ShProcess = ShellManagedProcess( self, arguments, startupDir )
self.RunManagedProcess( self.ShProcess )

as it then runs as a Deadline “ManagedProcess” it will be able to capture and track any StdOut/Err and then combined with you simply setting the self.StdOutEncoding = "utf-16" in the InitializeProcess() function of this ManagedProcess class, it will also be able to handle the unique difference that Autodesk tweaked about their Stdout as I explained above.

Yes, you could possibly use “subprocess” in py lib but you would be in charge of handling the management of the process, encoded StdOut/Err handling and you would also not be able to use the Deadline “Run As User” switching feature if that is something you rely on. Personally, when in Deadline, I avoid the use of subprocess for render-time execution of processes on the Slave side. Using subprocess for client side operations within the context of job submission/modification is a separate thread. :wink:

Finally, as per Bobo’s comment about licensing advantages…? Perhaps, Thinkbox should dev this plugin if its going to be useful for users.

Hope that helps?

Thanks for detailed answer.
Let me try.

I think Thinkbox should support this naively.
I don’t see any reason to use other than 3dsmaxbatch.
It is faster and lic free and give more functionality.
I even think you should consider to use this for 3dsMax rednering.
it is worth for just the launching speed alone.

I can not make this work… probably I don’t understand properly

Could you post modified CommandlinePlugin?

Privacy | Site terms | Cookie preferences