On this page |
Package-level functions ¶
The following top-level attribute functions are designed to be used in parameters with Python expressions. You can use pdg.workItem()
to get the current work item object in a Python expression, and use it to access other methods and properties from the pdg.WorkItem class. For example, the Python expressions pdg.workItem().floatAttribValue("foo", 1)
and pdg.WorkItem()["foo"][1]
are equivalent to the HScript expression @foo.1
.
input(index=None, tag=None, localize=False)
→ list
or str
Returns the input files of the current work item.
This is intended to be used in Python expressions. The HScript expression equivalent is @pdg_input
.
The return type depends on the index
keyword argument. If index=None
, the function returns a list of input files. Otherwise, it returns the indexth input file path.
isEvaluating()
→ bool
Returns True
if the calling thread is evaluating a PDG work item, else returns False
.
kwargs(key=None)
→ obj
or dict
This is intended to be used in Python expressions. Looks up a local variable from the expression evaluation context.
The return type depends on the key
keyword argument. If key=None
, the function returns all local variables as a dict
. Otherwise, it returns the value for the given key
.
workItem()
→ pdg.WorkItem
This is intended to be used in Python expressions. Returns the current work item object.
API ¶
attributes ¶
-
A file array work item attribute.
-
An floating point array work item attribute.
-
An integer array work item attribute.
-
A utility for matching attribute names to a pattern.
-
A Python object work item attribute.
-
A string array work item attribute.
-
Base class for pdg.AttributePattern and pdg.ValuePattern.
-
A file object with a path and associated metadata
-
Functions for mapping file paths
-
An entry in the global path map
-
A utility for matching values or producing arrays of values
-
The enumeration of error handling options when adding attributes to a work item
-
The enumeration of work item attribute flags
-
The enumeration of the default attribute pattern match types
-
The enumeration of different merge operations that can be applied to attributes
-
The enumeration of work item attribute overwrite options
-
The enumeration of work item attribute types
-
The enumeration of file transfer destination types
-
Enumeration of string matching types used when comparing a path mapping entry with an input string
cooking ¶
-
Container for cook options.
-
Container for graph evaluation options
-
The enumeration of file caching modes available on processor nodes
-
The enumeration of possible cook modes
-
The enumeration of work item generation modes supported by processor nodes
-
Enumeration of possible reasons for a node to regenerate during the cook
data ¶
-
The enumeration of PDG data types
-
The type of work item generation being performed by generation callbacks
debugging ¶
-
The enumeration of cache debug log levels
-
The enumeration of attribute expression debug log levels
-
The enumeration of node debug log levels
-
The enumeration of scheduler debug log levels
-
The enumeration of service debug log levels
-
The enumeration of file transfer debug log levels
-
pdg.debugLevelTypeRegistration
The enumeration of type registration debug log levels
-
The enumeration of work item debug log levels
-
The enumeration of debug logs available in PDG
-
Debug logging utilities
events ¶
-
Represents an event that occurred while the graph was running.
-
Base class for objects that are able to emit events
-
Represents a handler function added to a node or graph.
-
The type of a pdg.Event
exceptions ¶
-
Generic exception raised when an error occurs when accessing work item attributes
-
Generic exception raised when an error running the graph.
-
Generic exception raised when an error occurs during a PDG service manager operation
expressions ¶
-
A module with global functions that operate on the thread-local evaluation context
internal ¶
-
Memory info about a node and its work items
nodes ¶
-
Represents an external dependency of a node.
-
Dependency graph processor node subclass for feedback loop begin blocks
-
Represents a node’s dependence on the existence of an external file.
-
Represents the dependency graph within the GraphContext object.
-
The top level object in a dependency graph.
-
Base class for dependency graph nodes.
-
Summary info used to configure a pdg.Node instance
-
Generate and cook time information for a PDG node
-
An input, output or parameter on a PDG Node
-
Dependency graph node subclass representing a processor.
-
Cook time statistics exposed by a PDG node
-
The subtype of PDG node type
-
The primary type of a PDG node
-
The type of a pdg.Port object
schedulers ¶
-
A scheduler object that has its type implemented in Python.
-
Represents a scheduler in the dependency graph.
-
The ways that the scheduler can transfer work item data to remote machines
services ¶
-
Object that represents a service
-
Object containing the registry of all PDG services
-
Indicates the owner of a PDG service
-
Indicates the state of a PDG service
types ¶
-
A utility class return as the result of a custom file transfer handler
-
Object containing registry of all custom node, work item, and scheduler types.
-
The return type of a onAcceptWorkItem callback
-
The enumeration of cache results that can be returned by a custom cache handler
-
The enumeration of possible dirty handler types
-
The enumeration of languages used to define custom PDG types
-
The enumeration of possible result returned by a custom regeneration handler
-
The type of object when registering a custom class with PDG
-
The return type of a node callback implementation
-
The return type of a scheduler’s onScheduler callback implementation
-
The return type of a onTick callback
-
The enumeration of file transfers results that can be returned by a custom transfer handler
-
The return type of a scheduler’s isWorkItemReady call
workitems ¶
-
Represents a batch work item, which contains multiple child work items.
-
A list of read-only work items
-
Container object for dependency pairs.
-
Keeps track of work items inside a partition.
-
Custom work item data type for items that cook using a Python script
-
A work item in the PDG graph.
-
Exposes methods to access work item data through Python
-
Stores an in-progress Work Item dirty operation that can applied later
-
Container object for work items.
-
A list of work items
-
You can pass this object to WorkItemHolder.addWorkItem() to create a work item with the specified options.
-
Cook time information for a work item
-
The enumeration of batch activation conditions
-
The enumeration of clone modes that can be used when generating work items
-
The cook type of the work item
-
The type of dirty being performed on the graph
-
The execution type of the work item
-
Work item log message type
-
Processing time statistics exposed by a PDG work item
-
The cook state of the work item
-
The type of the work item