Working on a python filter to render tiles and need to name each tile dynamically I've tried to setproperty on image:filename and plane:filename but the IFD filename still gets used!
Anyone able to shine a light on my dim area of knowledge of houdini filters?
Cheers
Jamie
better explanation here:
http://forums.odforce.net/index.php?/topic/10335-p-python-filtering-imagefilename-set-property-problem/ [forums.odforce.net]
Mantra Python filter property to set filename differently
7454 6 2- TxRx
- Member
- 18 posts
- Joined: 8月 2007
- Offline
- symek
- Member
- 1390 posts
- Joined: 7月 2005
- Offline
txrx
Working on a python filter to render tiles and need to name each tile dynamically I've tried to setproperty on image:filename and plane:filename but the IFD filename still gets used!
Anyone able to shine a light on my dim area of knowledge of houdini filters?
Cheers
Jamie
better explanation here:
http://forums.odforce.net/index.php?/topic/10335-p-python-filtering-imagefilename-set-property-problem/ [forums.odforce.net]
Perhaps the easiest way would be to overwrite output via command line:
mantra -P ./filterMantra.py -f myIfd.ifd ./myoutputfile.exr
- TxRx
- Member
- 18 posts
- Joined: 8月 2007
- Offline
Hi there,
Thanks for your help on this. So there's no way the python filter script can access/change the output name I take it? That's ok
The command line is generated on the nodes using a Python wrapper to also set DB elements and env vars in place so I'll make it call the pytile script to get the proper name amendment output at the end of the commandline and executed on the nodes.
Thanks again for your help!
J
PS: Incidently where's the best place to post? Here or Od since I feel I've just double posted
Thanks for your help on this. So there's no way the python filter script can access/change the output name I take it? That's ok
The command line is generated on the nodes using a Python wrapper to also set DB elements and env vars in place so I'll make it call the pytile script to get the proper name amendment output at the end of the commandline and executed on the nodes.
Thanks again for your help!
J
PS: Incidently where's the best place to post? Here or Od since I feel I've just double posted
- niko3d
- Member
- 338 posts
- Joined: 9月 2006
- Offline
Was just thinking about this issue jamie.
This may cause issues with our setup
“mantra -P ./filterMantra.py -f myIfd.ifd ./myoutputfile.exr”
Not that its wrong but more of how we are exporting the .exr files. We dont save a single exr file out that include our imageplanes. We have a separate exr file for each plane.
So we need to be able to set a path for each image plane, as well as stitching each image plane together after wards.
For any of that to work you need to know the imageplane contents from the IFD, unless we can search through the IFD for imagePlanes contents using your python script to do this. Even with that im not sure if we can set imageplane outputs through command line?
Maybe we can redirect all the outputs to a tile folder.
Havent tried this but it may work…
mantra -P ./filterMantra.py -f myIfd.ifd ./myOutputTileFolder1/
mantra -P ./filterMantra.py -f myIfd.ifd ./myOutputTileFolder2/
mantra -P ./filterMantra.py -f myIfd.ifd ./myOutputTileFolder3/
Then you can simply scan the output directory for all tiles and compile them together.
Thinking outloud here , A cheeky workaround and not a great one to be honest, is to generate multiple ifds but using an enviroment var in the folder path for controlling the tile number… i.e $TILENUMBER, which you can set before the IFD job runs. I suppose its similar to a wedge rop, but controlled at a renderfarm level. Maybe we can do a post renderscript to set this so it is generic.
Either way a python filter or commandline option would be best if it was possible.
Downside means multiple IFDs, its not generic and requires user input rather then simply telling the farm to render tiles.
Cheers
Nick
This may cause issues with our setup
“mantra -P ./filterMantra.py -f myIfd.ifd ./myoutputfile.exr”
Not that its wrong but more of how we are exporting the .exr files. We dont save a single exr file out that include our imageplanes. We have a separate exr file for each plane.
So we need to be able to set a path for each image plane, as well as stitching each image plane together after wards.
For any of that to work you need to know the imageplane contents from the IFD, unless we can search through the IFD for imagePlanes contents using your python script to do this. Even with that im not sure if we can set imageplane outputs through command line?
Maybe we can redirect all the outputs to a tile folder.
Havent tried this but it may work…
mantra -P ./filterMantra.py -f myIfd.ifd ./myOutputTileFolder1/
mantra -P ./filterMantra.py -f myIfd.ifd ./myOutputTileFolder2/
mantra -P ./filterMantra.py -f myIfd.ifd ./myOutputTileFolder3/
Then you can simply scan the output directory for all tiles and compile them together.
Thinking outloud here , A cheeky workaround and not a great one to be honest, is to generate multiple ifds but using an enviroment var in the folder path for controlling the tile number… i.e $TILENUMBER, which you can set before the IFD job runs. I suppose its similar to a wedge rop, but controlled at a renderfarm level. Maybe we can do a post renderscript to set this so it is generic.
Either way a python filter or commandline option would be best if it was possible.
Downside means multiple IFDs, its not generic and requires user input rather then simply telling the farm to render tiles.
Cheers
Nick
- wolfwood
- Member
- 4271 posts
- Joined: 7月 2005
- Offline
- TxRx
- Member
- 18 posts
- Joined: 8月 2007
- Offline
Thanks for the reply. I'm going to avoid using multiple IFDs and image planes for the mean time. The main thinking behind this is to remove the need to re-render IFDs and try and keep as much of the tile-rendering on the farm functionality to the mantra python wrapper.
Additionally I'm looking to get this base functionality working then we can add more features to it as we progress.
I'll make the farms python mantra wrapper check for the render huge tile flags from the farm and call the tile co-ord function from the python filter and append the file name with the tile co-ords for the auto-stitcher script to re-join etc..
I can see how it works, slight shame that python filtering doesn't reach into the output api of the render but hey, that's not the end of the world!
'xpect me to be spamming these forums a little more in weeks ahead Nick!
Additionally I'm looking to get this base functionality working then we can add more features to it as we progress.
I'll make the farms python mantra wrapper check for the render huge tile flags from the farm and call the tile co-ord function from the python filter and append the file name with the tile co-ords for the auto-stitcher script to re-join etc..
I can see how it works, slight shame that python filtering doesn't reach into the output api of the render but hey, that's not the end of the world!
'xpect me to be spamming these forums a little more in weeks ahead Nick!
- symek
- Member
- 1390 posts
- Joined: 7月 2005
- Offline
-
- Quick Links