Can you post the Python Processor code you're using, or possibly the whole .hip file?
Both pdgcmd and pdgjson should be available on the python path for all work items, since they're copied to $PDGTEMP/scripts.
Found 439 posts.
Search results Show results as topic list.
PDG/TOPs » Python processor external script can't import pdgcmd/pdgjson
- tpetrick
- 586 posts
- Offline
PDG/TOPs » PDG color wedge to GLTF
- tpetrick
- 586 posts
- Offline
In a string parameter, you need to use backticks so that Houdini can tell you're entering a string expression, not a constant string. -- `@body_shader` in your case. This is the same for any HScript expression in a string parameter: https://www.sidefx.com/docs/houdini/network/expressions.html#string-parameters [www.sidefx.com]
PDG/TOPs » PDG color wedge to GLTF
- tpetrick
- 586 posts
- Offline
Your Sphere_02 material isn't working because your color components values are all set to @color. You need to use @color.r, @color.g and @color.b instead to access each of the components of the attribute value. The expression @color is the same as @color.0 or @color.r -- it will only accesses the first component of the attribute:
With that change, the Sphere_02 material exports properly and shows up in the viewport.
With that change, the Sphere_02 material exports properly and shows up in the viewport.
PDG/TOPs » PDG color wedge to GLTF
- tpetrick
- 586 posts
- Offline
Can you attach the .hip file with your TOPs and GLTF setup -- or one that reproduces the issue you're running into?
PDG/TOPs » custom range genarate
- tpetrick
- 586 posts
- Offline
The Range Generate node supports that in Houdini 19.0 -- it was also backported to H18.5, and should be available from builds 18.5.514 and newer.
You can change the range type to "Custom Range", and then use a pattern to specify the frame range. For example 1001 1003 1004 1006-1011 1020-1030:2, using your example.
You can change the range type to "Custom Range", and then use a pattern to specify the frame range. For example 1001 1003 1004 1006-1011 1020-1030:2, using your example.
PDG/TOPs » Geometry Import issues
- tpetrick
- 586 posts
- Offline
Note that starting with tomorrow's daily build of H19.0, you'll be able to configure the grouping behavior on the TOP Geometry. Instead of always creating a point group per work item, you can pick between creating point or prim groups, a point or prim attribute, or no grouping at all if you just want the merged geo.
PDG/TOPs » How to set condition
- tpetrick
- 586 posts
- Offline
I've attached an example with a wedge that randomly creates one attribute, and then creates another one derived from the first one. I also included an example of how you might use the Split node based on a wedge value to separate out work items that match a condition.
PDG/TOPs » HDA Processor Batch Mode Questions
- tpetrick
- 586 posts
- Offline
Yea, a batch will process all of its work items in one process. Rather than cooking each work item individually, the batch itself is scheduled as a single logical job. For both ROP Fetch and HDA Processor batches are processed sequentially, however that's not a strict requirement. For example, if you're writing a custom work item job script that supports batching (or a Python Processor's onCookTask hook) you can process the items in the batch in whatever order you want.
The ROP Fetch node cooks batches by calling rop.render(..) over the whole frame range, so if an error occurs on a frame the entire operation ends early. Likewise for HDA Processor -- the work items are cooked in a loop, and a failure will cause the process to exit immediately.
The ROP Fetch node cooks batches by calling rop.render(..) over the whole frame range, so if an error occurs on a frame the entire operation ends early. Likewise for HDA Processor -- the work items are cooked in a loop, and a failure will cause the process to exit immediately.
Edited by tpetrick - 2022年2月22日 17:18:50
PDG/TOPs » How to set condition
- tpetrick
- 586 posts
- Offline
You can refer to wedge attribute values using the @attrib syntax or the pdgattrib(..) function in an HScript expression. For example, @scale.2 or pdgattrib("scale", 2) will both access the "scale" attribute at index 2.
On the wedge node itself it's possible to change the Wedge Type from Range to Value. You can then type in an expression that uses other prior wedge attributes to control the value.
On the wedge node itself it's possible to change the Wedge Type from Range to Value. You can then type in an expression that uses other prior wedge attributes to control the value.
PDG/TOPs » Node warning in Python processor
- tpetrick
- 586 posts
- Offline
From a Python Processor or a Python Script TOP, you can use the pdg.Node.cookWarning(..) method to add a non-fatal warning to the node. That'll show up as a yellow exclamation mark: https://www.sidefx.com/docs/houdini/tops/pdg/Node.html#cookWarning [www.sidefx.com]
In both of those nodes, that method can be called on the self variable available in the Python code, e.g. self.cookWarning("Missing input files").
In both of those nodes, that method can be called on the self variable available in the Python code, e.g. self.cookWarning("Missing input files").
Edited by tpetrick - 2022年2月17日 17:55:39
PDG/TOPs » ROPFetch hangs when run using hython command line
- tpetrick
- 586 posts
- Offline
PDG/TOPs » PDG Partition by Index Question
- tpetrick
- 586 posts
- Offline
You can split the attribute back into work items using a Work Item Expand TOP, by setting the expansion type to "Upstream Attribute", specifying the name of the attribute, and enabling the "Expand as Work Item IDs" toggle.
PDG/TOPs » filepattern1
- tpetrick
- 586 posts
- Offline
In order to use the FFMPEG node, you need all of the files to be listed on a single work item. You can do that in one of two ways -- either put a wait for all after the file pattern, or uncheck "Split Files into Separate Items" on the file pattern. Your .hip file also has an FFMPEG Extract Images node, which is for converting a video file into images. You probably meant to use FFMPEG Encode Video instead, which creates a video from images.
For the ROP Composite, set the output path to something like $HIP/png/`@filename`.png. That allows you to rename the file from a .exr to .png, using the same file name as the input.
For the ROP Composite, set the output path to something like $HIP/png/`@filename`.png. That allows you to rename the file from a .exr to .png, using the same file name as the input.
PDG/TOPs » filepattern1
- tpetrick
- 586 posts
- Offline
The file pattern node creates work items with files listed as outputs for that work item. In order to reference them, the downstream node needs to use the @pdg_input variable or pdginput(..) function in an expression. When cooking with a ROP Composite TOP, ROP Geometry, etc you can use PDG expressions on the nodes cooked by the ROP as well.
If you're running into a specific issue, please upload a .hip file so that someone can take a look.
If you're running into a specific issue, please upload a .hip file so that someone can take a look.
PDG/TOPs » ROP Fetch external hip files? (╯°□°)╯︵ ┻━┻
- tpetrick
- 586 posts
- Offline
The ROP Fetch node looks for parms on the ROP that define output files so that it can report those files back to PDG. When a node doesn't have any output parms that often indicates an issue with the set up, hence the warning.
The Merge ROP doesn't have any output file parms so the PDG job warns you about potentially cooking an invalid ROP. The ROP Fetch supports cooking all leaf ROPs in a given network, so one option that may work for you is to remove the Merge and point the ROP Fetch at the network instead.
The Merge ROP doesn't have any output file parms so the PDG job warns you about potentially cooking an invalid ROP. The ROP Fetch supports cooking all leaf ROPs in a given network, so one option that may work for you is to remove the Merge and point the ROP Fetch at the network instead.
PDG/TOPs » Trying to set the same port, local vs remote
- tpetrick
- 586 posts
- Offline
andrewlowell
We also noticed that, although we're not using it, the HQueue scheduler has some functionality to provide a custom TCP port to use as the result server. Is it feasible to add this feature to the base Python scheduler?
Which parameters are you referring to? As far as I know, the parameters for configuring ports on the HQ scheduler are for customizing the ports used by the message queue service.
andrewlowell
The developer is currently writing a custom python scheduler - any chance you could point us to some documentation on how we might integrate a custom RPC endpoint with the rest of PDG so that it can handle the scheduling/result RPC communication?
There isn't any documentation on that since the RPC server is mostly an internal implementation detail. However, since all of the schedulers are written in Python, the code for the schedulers is still available as part of a Houdini installation. All schedulers subclass from the same two classes -- the pdg.Scheduler.PyScheduler base class, and the CallbackServerMixin mix-in class that defines the RPC server logic. For example, the Local Scheduler defined in $HH/pdg/types/schedulers/local.py. The callback server mix-in itself is defined in $HH/pythonX.Ylibs/pdg/job/callbackserver.py.
The documentation for writing a custom schedulers includes examples that are derived from the Local Scheduler: https://www.sidefx.com/docs/houdini/tops/custom_scheduler.html [www.sidefx.com]
In order to change the RPC server construction you'd need to write one from scratch that uses your own implementation of CallbackServerMixin that constructs the RPC server in the way that you want.
PDG/TOPs » Trying to set the same port, local vs remote
- tpetrick
- 586 posts
- Offline
It currently isn't possible to customize the address of the internal result server used by PDG, unless you write a custom scheduler that constructs its own RPC endpoint at a fixed port. However, when submitting jobs to the farm the PDG MQ service should make it possible to avoid firewall issues. Every submission using one of the farm schedulers starts an MQ service job that the PDG graph connects to when the cook begins. Work items running as part of the cook also connect back to the same MQ to send results to PDG, which means that the work items don't need to directly communicate with the result server at any point in time. Each of the farm schedulers (Tractor, Deadline and HQueue) expose parameters to customize the ports used by the MQ service.
In the future, for urgent questions like this one it's much better to contact SideFX support instead of using the forum. The forums are not directly tracked by support or QA, and developers check them at their own leisure. This sticky thread has more details about submitting bugs and RFEs, which also applies to questions: https://www.sidefx.com/forum/topic/61697/ [www.sidefx.com]
In the future, for urgent questions like this one it's much better to contact SideFX support instead of using the forum. The forums are not directly tracked by support or QA, and developers check them at their own leisure. This sticky thread has more details about submitting bugs and RFEs, which also applies to questions: https://www.sidefx.com/forum/topic/61697/ [www.sidefx.com]
PDG/TOPs » ROP Fetch external hip files? (╯°□°)╯︵ ┻━┻
- tpetrick
- 586 posts
- Offline
The attributes in the docs specify what attributes the node will set on work items that it creates. Generally speaking, nodes will always overwrite those attributes with values based on their parm configuration. The exception are nodes like Attribute Create or Environment Edit, which have parameter that you can set to controls what happens when a type conflict occurs or when an attribute already exists.
Edited by tpetrick - 2021年12月9日 14:36:58
PDG/TOPs » ROP Fetch external hip files? (╯°□°)╯︵ ┻━┻
- tpetrick
- 586 posts
- Offline
The Attribute Create approach in your new file will not work because "External HIP File" is still disabled on the ROP Fetch. When that toggle is off, the ROP Fetch will explicitly set the "hip" attribute to the path to the current scene file. It doesn't matter if you set it to a custom file path before hand -- the ROP Fetch will overwrite it because the parms on that node indicate that it should create work items that use the current file. The reason that wasn't happening in the first file is that there was a type mismatch, and the ROP Fetch implementation doesn't force the attribute type to update.
Green attributes are integers, yellow are floats, and magenta are strings. Anything that shows up in blue with an underline is a clickable link, like in a web browser. File attributes are string attributes that store additional meta data like a data type tag (such as a "file/hip"), the mod time/size of the file, and support path localization using PDG's path mapping so they load properly on different platforms.
Green attributes are integers, yellow are floats, and magenta are strings. Anything that shows up in blue with an underline is a clickable link, like in a web browser. File attributes are string attributes that store additional meta data like a data type tag (such as a "file/hip"), the mod time/size of the file, and support path localization using PDG's path mapping so they load properly on different platforms.
Edited by tpetrick - 2021年12月9日 13:28:30
PDG/TOPs » ROP Fetch external hip files? (╯°□°)╯︵ ┻━┻
- tpetrick
- 586 posts
- Offline
The "hip" attribute needs to be a file-type attribute, not a string attribute. Your Python Script is setting it as a string attribute, which is preventing the ROP Fetch itself from loading it properly when it goes to cook. The best way to do this is to store your custom file path string in a different attribute, and then reference it in by enabling the "External HIP File" parm on the ROP Fetch. For example, by setting that parm to @custom_hip, or whatever you've named your custom path attribute. That way the ROP Fetch a) configures the attribute properly and also b) expects to cook an external .hip file, instead of the current one.
Edited by tpetrick - 2021年12月9日 10:58:52
-
- Quick Links