substep Posted May 31, 2013 Share Posted May 31, 2013 Hi There, How Can I cache out .sim files of a dopnet through the command line? I tried searching, but most is for rendering through command Thanks! Quote Link to comment Share on other sites More sharing options...
Solitude Posted May 31, 2013 Share Posted May 31, 2013 Do you really need to cache the .sim file? Is there a reason you don't want to bring your geo/sim into sops and use a rop output driver? Quote Link to comment Share on other sites More sharing options...
substep Posted May 31, 2013 Author Share Posted May 31, 2013 (edited) I know what you mean, but this is just to quickly get an alembic file into maya, and still have the .sim on hand to cache everything out later. it probably seems strange , and I can do it from within houdini obviously, But I wanted to compare sim times through command I suppose and have that available to me. Edited May 31, 2013 by substep Quote Link to comment Share on other sites More sharing options...
jkunz07 Posted May 31, 2013 Share Posted May 31, 2013 Can't you just make a dynamics rop and execute it from the command line? hscript myfile.hip render -V /out/dynamicsrop Quote Link to comment Share on other sites More sharing options...
substep Posted May 31, 2013 Author Share Posted May 31, 2013 (edited) Thanks! I get unable to open file: ip error. any ideas? sorry for being so thick nevermind, I got it working. Many thanks! Edited May 31, 2013 by substep Quote Link to comment Share on other sites More sharing options...
jkunz07 Posted May 31, 2013 Share Posted May 31, 2013 It depends what OS your using - maybe this page http://www.sidefx.com/docs/houdini12.5/ref/utils/hscript helps Quote Link to comment Share on other sites More sharing options...
substep Posted May 31, 2013 Author Share Posted May 31, 2013 well, it's working, but isn't saving the .sim file correctly. I'm using $SF in the filename, but it seems to not like it. how can I fix that, and still cache substeps? Thanks! Quote Link to comment Share on other sites More sharing options...
Netvudu Posted May 31, 2013 Share Posted May 31, 2013 you´re not using Apprentice, or Apprentice HD, are you? Quote Link to comment Share on other sites More sharing options...
substep Posted May 31, 2013 Author Share Posted May 31, 2013 you´re not using Apprentice, or Apprentice HD, are you? No, but good thinking! Quote Link to comment Share on other sites More sharing options...
jkunz07 Posted May 31, 2013 Share Posted May 31, 2013 (edited) You may want to use $ST (simulation time) instead of $SF (simulation timestep number). Edited May 31, 2013 by jkunz07 Quote Link to comment Share on other sites More sharing options...
substep Posted May 31, 2013 Author Share Posted May 31, 2013 (edited) ahh I feel really stupid. many thanks! next beer's on me Edited May 31, 2013 by substep Quote Link to comment Share on other sites More sharing options...
substep Posted May 31, 2013 Author Share Posted May 31, 2013 (edited) ok wait, no. lol. $ST doesn't seem to work either. I can see it trying to write the file without the variable, replacing it with every frame. It does however work when I turn on "explicit cache" on the dopnet. But then it's wasting time writing both files, deleting one, writing both files, deleting one, etc, etc Edited May 31, 2013 by substep Quote Link to comment Share on other sites More sharing options...
Dispel Posted June 1, 2013 Share Posted June 1, 2013 If your sim timescale is 1.0, try $FF? If it's not, you can maybe eval some combination of $FF and timescale. Quote Link to comment Share on other sites More sharing options...
substep Posted June 1, 2013 Author Share Posted June 1, 2013 (edited) this kinda works, as the dynamics ROP accepts $FF as a variable, but it's not saving the substeps. It's frame for frame. If you look at how the DOPnet saves substepped .sim files - if you have 4 substeps, then frame one will have 4 .sim files named <filename>_1, _2, _3, _4. since it's using $ST. I'm still somewhat green to all this, so I obviously really don't understand, but could someone clear up why a "Dynamics" ROP that saves out .sim files won't save substeps? I suppose I could set my substeps to 1, and my simscale to .25. save out 4x as many frames, then read that back into a dopnet set to 4 substeps, and 1 sim scale...? maybe there's a better way? If I tag a file node onto the end of my network inside my DOPnet, can I cook that from the command line somehow? Edited June 1, 2013 by substep Quote Link to comment Share on other sites More sharing options...
Guest mantragora Posted June 1, 2013 Share Posted June 1, 2013 (edited) Kids, kids. Do I really have to fix everything for you Append fileDOP at the end of you sim network, set it to "Write" and use "$ST.sim" in it. And then add dynamics ROP in OUT and remember to turn on "Initialize Simulation OPs". Set its path to something that doesn't overwrite the name of fileDOP path (don't even use $F in it, let it write to the same file in each frame, call it "forceCook.sim" or something like that). Now try to call your ROP. It should force the network to cook and with it the fileDOP to write each substep. Edited June 1, 2013 by mantragora Quote Link to comment Share on other sites More sharing options...
substep Posted June 1, 2013 Author Share Posted June 1, 2013 (edited) haha, thanks! is this not still writing two .sim files to disk though? I just gave it a shot, and I get the same results as I did just turning on explicit cache on the dopnet, and letting the dynamics ROP error out writing over the same file since $SF didn't work in the dynamics ROP. So it still seems to be writing two .sim files to disk at once. if you stop the sim while the temp .sim file is being written, it's still the same file size as the wanted .sim files with or without $SF in the filename. please correct me if I've misunderstood it seems nice being able to run 4 bullet sims from the command line though, processors are maxed, and no gui. I guess we'll see how this goes. Edited June 1, 2013 by substep Quote Link to comment Share on other sites More sharing options...
Guest mantragora Posted June 1, 2013 Share Posted June 1, 2013 (edited) So set your ROP path to reference path parm of the fileDOP and set fileDOp to "No Operation", than ROP will save correctly and you will get one file saved only by it at a substep. Edited June 1, 2013 by mantragora Quote Link to comment Share on other sites More sharing options...
substep Posted June 1, 2013 Author Share Posted June 1, 2013 (edited) I was really hoping this was gonna work. But the "render" never starts, it just hangs. I did notice though when referencing the path of the file dop into the dynamics rop, that it didnt turn green. maybe it doesn't accept reference? edit: actually, it started after about 3 minutes. but it's only writing every odd frame. hmmm ? I believe I have two substeps on this sim. I did notice though, that by using the file dop, or explicit cache on the dopnet, and writing over the same file in the dynamics rop, it only writes the temp .sim file every frame, not every substep. So I guess that's a little better than what I originally thought. Edited June 1, 2013 by substep Quote Link to comment Share on other sites More sharing options...
Guest mantragora Posted June 1, 2013 Share Posted June 1, 2013 (edited) I was really hoping this was gonna work. But the "render" never starts, it just hangs. I did notice though when referencing the path of the file dop into the dynamics rop, that it didnt turn green. maybe it doesn't accept reference? As long as it works color doesn't matter. So does it work for you or do I have to attach example file? In my previous message I accidentally used $SF in fileDOP and that's why I though that it stopped working . After setting fileDOP to $ST, ROP again started to save the correct files again. Edited June 1, 2013 by mantragora Quote Link to comment Share on other sites More sharing options...
substep Posted June 1, 2013 Author Share Posted June 1, 2013 Yes, and example would be nice. As $SF in the file dop referenced into the dynamics rop only writes odd frames (1, 3, 5, etc), and using $ST in the file dop referenced into the dynamics rop gives me horribly misnumbered .sim files. I can only assume I'm doing something wrong, but everything your saying is clear as day to me. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.