Jump to content

start render without open the HIP


Recommended Posts

You can use hscript in a shell to open/navigate/manipulate a hip file
 

hscript -v /path/to/file.hip    # open the file
opcd /out                       # navigate in /out context
opls                            # list nodes
render nameOfMantraNode ; q     # push the "render" button on your mantra node and quit once finished.

alternative to last line can be

opparm -c nameOfMantraNode execute ; q

which will simulate you pushing the button render on the mantra Node.
 

  • Like 3
Link to comment
Share on other sites

If you bake out your geometry/volume caches to bgeo, you can set the File SOP's Load parm to Packed Disk Primitive; also, set your cook mode to manual, you might have to save and reopen your hip file to clear the cache, and hit render.

:( Unfortunately the file was import form 3dsmax with fbx. I save to houdini hip file. The hip file size up to 6 GB. and i cannot export it to abc or obj form 3dsmax because fbx have the material path. 

Since fbx load every gruop polygon as a geo. So i cannot just save it to bgeo.sc or something packed. I already set viewport to manual. It still took me 15G to open it.

If anyway to render it without open the hip?

Or i will try to optimize it, merge them as one object by python.

Link to comment
Share on other sites

You can use hscript in a shell to open/navigate/manipulate a hip file

 

hscript -v /path/to/file.hip    # open the file
opcd /out                       # navigate in /out context
opls                            # list nodes
render nameOfMantraNode ; q     # push the "render" button on your mantra node and quit once finished.

alternative to last line can be

opparm -c nameOfMantraNode execute ; q

which will simulate you pushing the button render on the mantra Node.

 

Thanks. Anthony. :)

Working perfect on windows, i will try on linux soon.

Link to comment
Share on other sites

You can use hscript in a shell to open/navigate/manipulate a hip file

 

hscript -v /path/to/file.hip    # open the file
opcd /out                       # navigate in /out context
opls                            # list nodes
render nameOfMantraNode ; q     # push the "render" button on your mantra node and quit once finished.

alternative to last line can be

opparm -c nameOfMantraNode execute ; q

which will simulate you pushing the button render on the mantra Node.

 

After source  houdini_setup.

Linux shell also working perfect!

Thanks.Anthony.

Link to comment
Share on other sites

You can use hscript in a shell to open/navigate/manipulate a hip file

 

hscript -v /path/to/file.hip    # open the file
opcd /out                       # navigate in /out context
opls                            # list nodes
render nameOfMantraNode ; q     # push the "render" button on your mantra node and quit once finished.

alternative to last line can be

opparm -c nameOfMantraNode execute ; q

which will simulate you pushing the button render on the mantra Node.

 

:mellow:

 And i find the hscript to load the hip file also took me 13GB ram.

So the problem was my terrible fbx file, i have try to merge them as one object.

Anyway, thanks.

Link to comment
Share on other sites

i think the way houdini imports fbx is to actually lock off the geometry in sops which means that the data is contained inside the hip file.  kinda sol in that regard.  you should consider writing out ifds and launching mantra as a separate task so you don't need houdini open during the rendering process.

Link to comment
Share on other sites

i think the way houdini imports fbx is to actually lock off the geometry in sops which means that the data is contained inside the hip file.  kinda sol in that regard.  you should consider writing out ifds and launching mantra as a separate task so you don't need houdini open during the rendering process.

Thanks. Miles.

Could you show me how to set a ifds, i never used it before.

Link to comment
Share on other sites

ifd = Instantaneous Frame Description.  they are the direct commands mantra uses to render a frame.  mantra does not need houdini running in order to render, it simply needs the commands generated by houdini.  this means you can generate those commands to a series of files (1 per frame) and then launch mantra to do the actual rendering.  the benefit for you would be that houdini would not be loaded and taking up your ram at the same time your frames are rendering.

 

to generate ifds, you simply toggle on the "Disk File" toggle in the "Driver" tab on your rop.  then you need to find a suitable location for your ifd's and name them something appropriate (with $F in the name if you have multiple frames).  then when you click render to disk, it will just do the ifd generation.

 

the hard part is then processing those ifds thru mantra.  it's not hard per se, but you need to call mantra over and over again as each frame is completed.  it's basically the job of a render farm/manager.

 

if you're just doing a single frame, you could probably manage it manually.  but more than that is rough -- particularly on windows.

 

how many frames you want to render?  do you have any kind of render farm software?

  • Like 2
Link to comment
Share on other sites

ifd = Instantaneous Frame Description.  they are the direct commands mantra uses to render a frame.  mantra does not need houdini running in order to render, it simply needs the commands generated by houdini.  this means you can generate those commands to a series of files (1 per frame) and then launch mantra to do the actual rendering.  the benefit for you would be that houdini would not be loaded and taking up your ram at the same time your frames are rendering.

 

to generate ifds, you simply toggle on the "Disk File" toggle in the "Driver" tab on your rop.  then you need to find a suitable location for your ifd's and name them something appropriate (with $F in the name if you have multiple frames).  then when you click render to disk, it will just do the ifd generation.

 

the hard part is then processing those ifds thru mantra.  it's not hard per se, but you need to call mantra over and over again as each frame is completed.  it's basically the job of a render farm/manager.

 

if you're just doing a single frame, you could probably manage it manually.  but more than that is rough -- particularly on windows.

 

how many frames you want to render?  do you have any kind of render farm software?

Thanks. Miles.

I have try ifds on my linux, it works well as your said when i just test one frame.

So the task was lots of frames, and i never working on any render farm before.  :(

I hope any free trail render farm can be test. What are the Hqueue doing?

Link to comment
Share on other sites

if you have linux, then scripting up a loop shouldn't be too hard.

 

#!/bin/csh
 
set START = 1
set END = 100
 
set FRAME = $START
 
while ($FRAME <= $END)
     mantra -f myFile.$FRAME.ifd
 
    @ FRAME = $FRAME + 1
end
 

 

that's a really basic loop in csh.  it'll iterate over your frame range (change START and END to be whatever you want).  you'll need to specify your complete ifd location.  also, use $F in the ifd write and not $F4 (this loop doesn't handle padding with 0's).

 

you'll need to save that to a file and "chmod +x" the file to make it executable.

 

good luck.

  • Like 1
Link to comment
Share on other sites

if you have linux, then scripting up a loop shouldn't be too hard.

#!/bin/csh
 
set START = 1
set END = 100
 
set FRAME = $START
 
while ($FRAME <= $END)
     mantra -f myFile.$FRAME.ifd
 
    @ FRAME = $FRAME + 1
end
 

that's a really basic loop in csh.  it'll iterate over your frame range (change START and END to be whatever you want).  you'll need to specify your complete ifd location.  also, use $F in the ifd write and not $F4 (this loop doesn't handle padding with 0's).

 

you'll need to save that to a file and "chmod +x" the file to make it executable.

 

good luck.

Great appreciate for your help. Miles.

I can do it convenient now, several days before i just know nothing about this.

:)

Link to comment
Share on other sites

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.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...