ladybug_vtk.joined_polydata module¶
A VTK Appended Polydata object with additional methods.
- class ladybug_vtk.joined_polydata.JoinedPolyData[source]¶
Bases:
vtkAppendPolyData
A thin wrapper around vtk.vtkAppendPolyData.
- class DesiredOutputPrecision¶
Bases:
int
- as_integer_ratio()¶
Return a pair of integers, whose ratio is equal to the original int.
The ratio is in lowest terms and has a positive denominator.
>>> (10).as_integer_ratio() (10, 1) >>> (-10).as_integer_ratio() (-10, 1) >>> (0).as_integer_ratio() (0, 1)
- bit_count()¶
Number of ones in the binary representation of the absolute value of self.
Also known as the population count.
>>> bin(13) '0b1101' >>> (13).bit_count() 3
- bit_length()¶
Number of bits necessary to represent self in binary.
>>> bin(37) '0b100101' >>> (37).bit_length() 6
- conjugate()¶
Returns self, the complex conjugate of any int.
- from_bytes(byteorder='big', *, signed=False)¶
Return the integer represented by the given array of bytes.
- bytes
Holds the array of bytes to convert. The argument must either support the buffer protocol or be an iterable object producing bytes. Bytes and bytearray are examples of built-in objects that support the buffer protocol.
- byteorder
The byte order used to represent the integer. If byteorder is ‘big’, the most significant byte is at the beginning of the byte array. If byteorder is ‘little’, the most significant byte is at the end of the byte array. To request the native byte order of the host system, use `sys.byteorder’ as the byte order value. Default is to use ‘big’.
- signed
Indicates whether two’s complement is used to represent the integer.
- is_integer()¶
Returns True. Exists for duck type compatibility with float.is_integer.
- to_bytes(length=1, byteorder='big', *, signed=False)¶
Return an array of bytes representing an integer.
- length
Length of bytes object to use. An OverflowError is raised if the integer is not representable with the given number of bytes. Default is length 1.
- byteorder
The byte order used to represent the integer. If byteorder is ‘big’, the most significant byte is at the beginning of the byte array. If byteorder is ‘little’, the most significant byte is at the end of the byte array. To request the native byte order of the host system, use `sys.byteorder’ as the byte order value. Default is to use ‘big’.
- signed
Determines whether two’s complement is used to represent the integer. If signed is False and a negative integer is given, an OverflowError is raised.
- denominator¶
the denominator of a rational number in lowest terms
- imag¶
the imaginary part of a complex number
- numerator¶
the numerator of a rational number in lowest terms
- real¶
the real part of a complex number
- classmethod from_polydata(polydata: List[PolyData])[source]¶
Join several polygonal datasets.
This function merges several polygonal datasets into a single polygonal datasets. All geometry is extracted and appended, but point and cell attributes (i.e., scalars, vectors, normals) are extracted and appended only if all datasets have the point and/or cell attributes available. (For example, if one dataset has point scalars but another does not, point scalars will not be appended.)
- override()¶
This method can be used to override a VTK class with a Python subclass. The class type passed to override will afterwards be instantiated instead of the type override is called on. For example,
- class foo(vtk.vtkPoints):
pass
vtk.vtkPoints.override(foo)
will lead to foo being instantied everytime vtkPoints() is called. The main objective of this functionality is to enable developers to extend VTK classes with more pythonic subclasses that contain convenience functionality.
- to_folder(target_folder='.')[source]¶
Write data to a folder with a JSON meta file.
This method generates a folder that includes a JSON meta file along with all the binary arrays written as standalone binary files.
The generated format can be used by vtk.js using the reader below https://kitware.github.io/vtk-js/examples/HttpDataSetReader.html
- Parameters:
target_folder – Path to target folder. Default: .
- to_vtk(target_folder: str, name: str, writer: VTKWriters = VTKWriters.binary)[source]¶
Write to a VTK file.
The file extension will be set to vtk for ASCII format and vtp for binary format.
- AbortExecuteOff¶
virtual void AbortExecuteOff()
- Type:
C++
- AbortExecuteOn¶
virtual void AbortExecuteOn()
- Type:
C++
- AddInputConnection¶
-> None C++: virtual void AddInputConnection(int port,
vtkAlgorithmOutput *input)
AddInputConnection(self, input:vtkAlgorithmOutput) -> None C++: virtual void AddInputConnection(vtkAlgorithmOutput *input)
Add a connection to the given input port index. See SetInputConnection() for details on input connections. This method is the complement to RemoveInputConnection() in that it adds only the connection specified without affecting other connections. Typical usage is
filter2->AddInputConnection(0, filter1->GetOutputPort(0)).
- AddInputData¶
void AddInputData(vtkPolyData *)
Add a dataset to the list of data to append. Should not be used when UserManagedInputs is true, use SetInputByNumber instead.
- Type:
C++
- AddInputDataObject¶
- virtual void AddInputDataObject(int port,
vtkDataObject *data)
AddInputDataObject(self, data:vtkDataObject) -> None C++: virtual void AddInputDataObject(vtkDataObject *data)
Add the data-object as an input to this given port. This will add a new input connection on the specified port without affecting any existing connections on the same input port.
- Type:
C++
- AddObserver¶
- unsigned long AddObserver(const char* event,
vtkCommand* command, float priority=0.0f)
Add an event callback command(o:vtkObject, event:int) for an event type. Returns a handle that can be used with RemoveEvent(event:int).
- Type:
C++
- BreakOnError¶
static void BreakOnError()
This method is called when vtkErrorMacro executes. It allows the debugger to break on error.
- Type:
C++
- CAN_HANDLE_PIECE_REQUEST¶
static vtkInformationIntegerKey *CAN_HANDLE_PIECE_REQUEST()
Key that tells the pipeline that a particular algorithm can or cannot handle piece request. If a filter cannot handle piece requests and is asked for a piece, the executive will flag an error. If a structured data source cannot handle piece requests but can produce sub-extents (CAN_PRODUCE_SUB_EXTENT), the executive will use an extent translator to split the extent into pieces. Otherwise, if a source cannot handle piece requests, the executive will ask for the whole data for piece 0 and not execute the source for other pieces.ingroup InformationKeys
- Type:
C++
- CAN_PRODUCE_SUB_EXTENT¶
static vtkInformationIntegerKey *CAN_PRODUCE_SUB_EXTENT()
This key tells the executive that a particular output port is capable of producing an arbitrary subextent of the whole extent. Many image sources and readers fall into this category but some such as the legacy structured data readers cannot support this feature.ingroup InformationKeys
- Type:
C++
- CheckAbort¶
bool CheckAbort()
Checks to see if this filter should abort.
- Type:
C++
- ConvertTotalInputToPortConnection¶
- int,
conn:int) -> None
- C++: void ConvertTotalInputToPortConnection(int ind, int &port,
int &conn)
Convenience routine to convert from a linear ordering of input connections to a port/connection pair.
- Type:
ConvertTotalInputToPortConnection(self, ind
- Type:
int, port
- DEFAULT_PRECISION = 2¶
- DOUBLE_PRECISION = 1¶
- DebugOff¶
virtual void DebugOff()
Turn debugging output off.
- Type:
C++
- DebugOn¶
virtual void DebugOn()
Turn debugging output on.
- Type:
C++
- FastDelete¶
virtual void FastDelete()
Delete a reference to this object. This version will not invoke garbage collection and can potentially leak the object if it is part of a reference loop. Use this method only when it is known that the object has another reference and would not be collected if a full garbage collection check were done.
- Type:
C++
- GetAbortExecute¶
virtual vtkTypeBool GetAbortExecute()
- Type:
C++
- GetAbortOutput¶
virtual bool GetAbortOutput()
- Type:
C++
- GetAddressAsString¶
Get address of C++ object in format ‘Addr=%p’ after casting to the specified type. This method is obsolete, you can get the same information from o.__this__.
- GetDebug¶
bool GetDebug()
Get the value of the debug flag.
- Type:
C++
- GetErrorCode¶
virtual unsigned long GetErrorCode()
The error code contains a possible error that occurred while reading or writing the file.
- Type:
C++
- GetExecutive¶
vtkExecutive *GetExecutive()
Get this algorithm’s executive. If it has none, a default executive will be created.
- Type:
C++
- GetGlobalWarningDisplay¶
static vtkTypeBool GetGlobalWarningDisplay()
- Type:
C++
- GetInformation¶
virtual vtkInformation *GetInformation()
Set/Get the information object associated with this algorithm.
- Type:
C++
- GetInput¶
vtkPolyData *GetInput(int idx) GetInput(self) -> vtkPolyData C++: vtkPolyData *GetInput()
Get any input of this filter.
- Type:
C++
- GetInputAlgorithm¶
-> vtkAlgorithm C++: vtkAlgorithm *GetInputAlgorithm(int port, int index,
int &algPort)
GetInputAlgorithm(self, port:int, index:int) -> vtkAlgorithm C++: vtkAlgorithm *GetInputAlgorithm(int port, int index) GetInputAlgorithm(self) -> vtkAlgorithm C++: vtkAlgorithm *GetInputAlgorithm()
Returns the algorithm and the output port index of that algorithm connected to a port-index pair.
- GetInputArrayInformation¶
vtkInformation *GetInputArrayInformation(int idx)
Get the info object for the specified input array to this algorithm
- Type:
C++
- GetInputConnection¶
-> vtkAlgorithmOutput C++: vtkAlgorithmOutput *GetInputConnection(int port, int index)
Get the algorithm output port connected to an input port.
- GetInputDataObject¶
-> vtkDataObject C++: vtkDataObject *GetInputDataObject(int port, int connection)
Get the data object that will contain the algorithm input for the given port and given connection.
- GetInputExecutive¶
vtkExecutive *GetInputExecutive(int port, int index) GetInputExecutive(self) -> vtkExecutive C++: vtkExecutive *GetInputExecutive()
Returns the executive associated with a particular input connection.
- Type:
C++
- GetInputInformation¶
vtkInformation *GetInputInformation(int port, int index) GetInputInformation(self) -> vtkInformation C++: vtkInformation *GetInputInformation()
Return the information object that is associated with a particular input connection. This can be used to get meta-data coming from the REQUEST_INFORMATION pass and set requests for the REQUEST_UPDATE_EXTENT pass. NOTE: Do not use this in any of the pipeline passes. Use the information objects passed as arguments instead.
- Type:
C++
- GetInputPortInformation¶
vtkInformation *GetInputPortInformation(int port)
Get the information object associated with an input port. There is one input port per kind of input to the algorithm. Each input port tells executives what kind of data and downstream requests this algorithm can handle for that input.
- Type:
C++
- GetIsInMemkind¶
bool GetIsInMemkind()
A local state flag that remembers whether this object lives in the normal or extended memory space.
- Type:
C++
- GetMTime¶
virtual vtkMTimeType GetMTime()
Return this object’s modified time.
- Type:
C++
- GetNumberOfGenerationsFromBase¶
- vtkIdType GetNumberOfGenerationsFromBase(const char *type)
override;
Given the name of a base class of this class type, return the distance of inheritance between this class type and the named class (how many generations of inheritance are there between this class and the named class). If the named class is not in this class’s inheritance tree, return a negative value. Valid responses will always be nonnegative. This method works in combination with vtkTypeMacro found in vtkSetGet.h.
- Type:
C++
- GetNumberOfGenerationsFromBaseType¶
- static vtkIdType GetNumberOfGenerationsFromBaseType(
const char *type)
Given a the name of a base class of this class type, return the distance of inheritance between this class type and the named class (how many generations of inheritance are there between this class and the named class). If the named class is not in this class’s inheritance tree, return a negative value. Valid responses will always be nonnegative. This method works in combination with vtkTypeMacro found in vtkSetGet.h.
- Type:
C++
- GetNumberOfInputConnections¶
int GetNumberOfInputConnections(int port)
Get the number of inputs currently connected to a port.
- Type:
C++
- GetNumberOfInputPorts¶
int GetNumberOfInputPorts()
Get the number of input ports used by the algorithm.
- Type:
C++
- GetNumberOfOutputPorts¶
int GetNumberOfOutputPorts()
Get the number of output ports provided by the algorithm.
- Type:
C++
- GetObjectDescription¶
std::string GetObjectDescription() override;
The object description printed in messages and PrintSelf output. To be used only for reporting purposes.
- Type:
C++
- GetObjectName¶
virtual std::string GetObjectName()
- Type:
C++
- GetOutput¶
vtkPolyData *GetOutput() GetOutput(self, __a:int) -> vtkPolyData C++: vtkPolyData *GetOutput(int)
Get the output data object for a port on this algorithm.
- Type:
C++
- GetOutputDataObject¶
vtkDataObject *GetOutputDataObject(int port)
Get the data object that will contain the algorithm output for the given port.
- Type:
C++
- GetOutputInformation¶
vtkInformation *GetOutputInformation(int port)
Return the information object that is associated with a particular output port. This can be used to set meta-data coming during the REQUEST_INFORMATION. NOTE: Do not use this in any of the pipeline passes. Use the information objects passed as arguments instead.
- Type:
C++
- GetOutputPointsPrecision¶
virtual int GetOutputPointsPrecision()
- Type:
C++
- GetOutputPort¶
vtkAlgorithmOutput *GetOutputPort(int index) GetOutputPort(self) -> vtkAlgorithmOutput C++: vtkAlgorithmOutput *GetOutputPort()
Get a proxy object corresponding to the given output port of this algorithm. The proxy object can be passed to another algorithm’s SetInputConnection(), AddInputConnection(), and RemoveInputConnection() methods to modify pipeline connectivity.
- Type:
C++
- GetOutputPortInformation¶
vtkInformation *GetOutputPortInformation(int port)
Get the information object associated with an output port. There is one output port per output from the algorithm. Each output port tells executives what kind of upstream requests this algorithm can handle for that output.
- Type:
C++
- GetParallelStreaming¶
virtual vtkTypeBool GetParallelStreaming()
- Type:
C++
- GetProgress¶
virtual double GetProgress()
Get the execution progress of a process object.
- Type:
C++
- GetProgressScale¶
virtual double GetProgressScale()
- Type:
C++
- GetProgressShift¶
virtual double GetProgressShift()
- Type:
C++
- GetReferenceCount¶
int GetReferenceCount()
Return the current reference count of this object.
- Type:
C++
- GetReleaseDataFlag¶
virtual vtkTypeBool GetReleaseDataFlag()
- Type:
C++
- GetTotalNumberOfInputConnections¶
int GetTotalNumberOfInputConnections()
Get the total number of inputs for this algorithm
- Type:
C++
- GetUpdateExtent¶
int *GetUpdateExtent() GetUpdateExtent(self, port:int) -> (int, int, int, int, int, int) C++: int *GetUpdateExtent(int port) GetUpdateExtent(self, x0:int, x1:int, y0:int, y1:int, z0:int,
z1:int) -> None
- C++: void GetUpdateExtent(int &x0, int &x1, int &y0, int &y1,
int &z0, int &z1)
- GetUpdateExtent(self, port:int, x0:int, x1:int, y0:int, y1:int,
z0:int, z1:int) -> None
- C++: void GetUpdateExtent(int port, int &x0, int &x1, int &y0,
int &y1, int &z0, int &z1)
- GetUpdateExtent(self, extent:[int, int, int, int, int, int])
-> None
C++: void GetUpdateExtent(int extent[6]) GetUpdateExtent(self, port:int, extent:[int, int, int, int, int,
int]) -> None
C++: void GetUpdateExtent(int port, int extent[6])
These functions return the update extent for output ports that use 3D extents. Where port is not specified, it is assumed to be 0.
- Type:
C++
- GetUpdateGhostLevel¶
int GetUpdateGhostLevel() GetUpdateGhostLevel(self, port:int) -> int C++: int GetUpdateGhostLevel(int port)
- Type:
C++
- GetUpdateNumberOfPieces¶
int GetUpdateNumberOfPieces() GetUpdateNumberOfPieces(self, port:int) -> int C++: int GetUpdateNumberOfPieces(int port)
- Type:
C++
- GetUpdatePiece¶
int GetUpdatePiece() GetUpdatePiece(self, port:int) -> int C++: int GetUpdatePiece(int port)
These functions return the update extent for output ports that use piece extents. Where port is not specified, it is assumed to be 0.
- Type:
C++
- GetUserManagedInputs¶
virtual vtkTypeBool GetUserManagedInputs()
- Type:
C++
- GetUsingMemkind¶
static bool GetUsingMemkind()
A global state flag that controls whether vtkObjects are constructed in the usual way (the default) or within the extended memory space.
- Type:
C++
- GlobalWarningDisplayOff¶
static void GlobalWarningDisplayOff()
- Type:
C++
- GlobalWarningDisplayOn¶
static void GlobalWarningDisplayOn()
- Type:
C++
- HasExecutive¶
vtkTypeBool HasExecutive()
Check whether this algorithm has an assigned executive. This will NOT create a default executive.
- Type:
C++
- HasObserver¶
vtkTypeBool HasObserver(unsigned long event, vtkCommand *) HasObserver(self, event:str, __b:vtkCommand) -> int C++: vtkTypeBool HasObserver(const char *event, vtkCommand *) HasObserver(self, event:int) -> int C++: vtkTypeBool HasObserver(unsigned long event) HasObserver(self, event:str) -> int C++: vtkTypeBool HasObserver(const char *event)
- Type:
C++
- INPUT_ARRAYS_TO_PROCESS¶
- static vtkInformationInformationVectorKey *INPUT_ARRAYS_TO_PROCESS(
)
ingroup InformationKeys
- Type:
C++
- INPUT_CONNECTION¶
static vtkInformationIntegerKey *INPUT_CONNECTION()
ingroup InformationKeys
- Type:
C++
- INPUT_IS_OPTIONAL¶
static vtkInformationIntegerKey *INPUT_IS_OPTIONAL()
Keys used to specify input port requirements.ingroup InformationKeys
- Type:
C++
- INPUT_IS_REPEATABLE¶
static vtkInformationIntegerKey *INPUT_IS_REPEATABLE()
ingroup InformationKeys
- Type:
C++
- INPUT_REQUIRED_DATA_TYPE¶
- static vtkInformationStringVectorKey *INPUT_REQUIRED_DATA_TYPE(
)
ingroup InformationKeys
- Type:
C++
- INPUT_REQUIRED_FIELDS¶
- static vtkInformationInformationVectorKey *INPUT_REQUIRED_FIELDS(
)
ingroup InformationKeys
- Type:
C++
- InitializeObjectBase¶
void InitializeObjectBase()
- Type:
C++
- InvokeEvent¶
int InvokeEvent(unsigned long event, void* callData) InvokeEvent(self, event:str, callData:Any) -> int C++: int InvokeEvent(const char* event, void* callData) InvokeEvent(self, event:int) -> int C++: int InvokeEvent(unsigned long event) InvokeEvent(self, event:str) -> int C++: int InvokeEvent(const char* event)
This method invokes an event and returns whether the event was aborted or not. If the event was aborted, the return value is 1, otherwise it is 0.
- Type:
C++
- IsA¶
vtkTypeBool IsA(const char *type) override;
Return 1 if this class is the same type of (or a subclass of) the named class. Returns 0 otherwise. This method works in combination with vtkTypeMacro found in vtkSetGet.h.
- Type:
C++
- IsTypeOf¶
static vtkTypeBool IsTypeOf(const char *type)
Return 1 if this class type is the same type of (or a subclass of) the named class. Returns 0 otherwise. This method works in combination with vtkTypeMacro found in vtkSetGet.h.
- Type:
C++
- Modified¶
virtual void Modified()
Update the modification time for this object. Many filters rely on the modification time to determine if they need to recompute their data. The modification time is a unique monotonically increasing unsigned long integer.
- Type:
C++
- ModifyRequest¶
virtual int ModifyRequest(vtkInformation *request, int when)
This method gives the algorithm a chance to modify the contents of a request before or after (specified in the when argument) it is forwarded. The default implementation is empty. Returns 1 on success, 0 on failure. When can be either vtkExecutive::BeforeForward or vtkExecutive::AfterForward.
- Type:
C++
- ParallelStreamingOff¶
virtual void ParallelStreamingOff()
- Type:
C++
- ParallelStreamingOn¶
virtual void ParallelStreamingOn()
- Type:
C++
- ProcessRequest¶
- vtkCollection,
outInfo:vtkInformationVector) -> int
- C++: vtkTypeBool ProcessRequest(vtkInformation *request,
Version of ProcessRequest() that is wrapped. This converts the collection to an array and calls the other version.
- Type:
ProcessRequest(self, request
- Type:
vtkInformation, inInfo
- PropagateUpdateExtent¶
virtual void PropagateUpdateExtent()
Propagate meta-data upstream.
- Type:
C++
- ReleaseDataFlagOff¶
void ReleaseDataFlagOff()
- Type:
C++
- ReleaseDataFlagOn¶
void ReleaseDataFlagOn()
- Type:
C++
- RemoveAllInputConnections¶
virtual void RemoveAllInputConnections(int port)
Removes all input connections.
- Type:
C++
- RemoveAllInputs¶
void RemoveAllInputs()
Remove all the input data.
- Type:
C++
- RemoveAllObservers¶
void RemoveAllObservers()
- Type:
C++
- RemoveInputConnection¶
-> None C++: virtual void RemoveInputConnection(int port,
vtkAlgorithmOutput *input)
RemoveInputConnection(self, port:int, idx:int) -> None C++: virtual void RemoveInputConnection(int port, int idx)
Remove a connection from the given input port index. See SetInputConnection() for details on input connection. This method is the complement to AddInputConnection() in that it removes only the connection specified without affecting other connections. Typical usage is
filter2->RemoveInputConnection(0, filter1->GetOutputPort(0)).
- RemoveInputData¶
void RemoveInputData(vtkPolyData *)
Remove a dataset from the list of data to append. Should not be used when UserManagedInputs is true, use SetInputByNumber (nullptr) instead.
- Type:
C++
- RemoveObserver¶
void RemoveObserver(vtkCommand *) RemoveObserver(self, tag:int) -> None C++: void RemoveObserver(unsigned long tag)
- Type:
C++
- RemoveObservers¶
void RemoveObservers(unsigned long event, vtkCommand *) RemoveObservers(self, event:str, __b:vtkCommand) -> None C++: void RemoveObservers(const char *event, vtkCommand *) RemoveObservers(self, event:int) -> None C++: void RemoveObservers(unsigned long event) RemoveObservers(self, event:str) -> None C++: void RemoveObservers(const char *event)
- Type:
C++
- SINGLE_PRECISION = 0¶
- SetAbortExecute¶
virtual void SetAbortExecute(vtkTypeBool _arg)
Set/Get the AbortExecute flag for the process object. Process objects may handle premature termination of execution in different ways.
- Type:
C++
- SetAbortExecuteAndUpdateTime¶
void SetAbortExecuteAndUpdateTime()
Set AbortExecute Flag and update LastAbortTime.
- Type:
C++
- SetAbortOutput¶
virtual void SetAbortOutput(bool _arg)
Set/Get an internal variable used to communicate between the algorithm and executive. If the executive sees this value is set, it will initialize the output data and pass the ABORTED flag downstream.
CheckAbort sets this value to true if the function returns true.
- Type:
C++
- SetContainerAlgorithm¶
void SetContainerAlgorithm(vtkAlgorithm *containerAlg)
Set/get a Container algorithm for this algorithm. Allows this algorithm to check to abort status of its Container algorithm as well as have access to its Container’s information.
- Type:
C++
- SetDebug¶
void SetDebug(bool debugFlag)
Set the value of the debug flag. A true value turns debugging on.
- Type:
C++
- SetDefaultExecutivePrototype¶
static void SetDefaultExecutivePrototype(vtkExecutive *proto)
If the DefaultExecutivePrototype is set, a copy of it is created in CreateDefaultExecutive() using NewInstance().
- Type:
C++
- SetExecutive¶
virtual void SetExecutive(vtkExecutive *executive)
Set this algorithm’s executive. This algorithm is removed from any executive to which it has previously been assigned and then assigned to the given executive.
- Type:
C++
- SetGlobalWarningDisplay¶
static void SetGlobalWarningDisplay(vtkTypeBool val)
This is a global flag that controls whether any debug, warning or error messages are displayed.
- Type:
C++
- SetInputArrayToProcess¶
- int, connection:int,
fieldAssociation:int, name:str) -> None
- C++: virtual void SetInputArrayToProcess(int idx, int port,
int connection, int fieldAssociation, const char *name)
- SetInputArrayToProcess(self, idx:int, port:int, connection:int,
fieldAssociation:int, fieldAttributeType:int) -> None
- C++: virtual void SetInputArrayToProcess(int idx, int port,
int connection, int fieldAssociation, int fieldAttributeType)
SetInputArrayToProcess(self, idx:int, info:vtkInformation) -> None C++: virtual void SetInputArrayToProcess(int idx,
vtkInformation *info)
- SetInputArrayToProcess(self, idx:int, port:int, connection:int,
fieldAssociation:str, attributeTypeorName:str) -> None
- C++: virtual void SetInputArrayToProcess(int idx, int port,
int connection, const char *fieldAssociation, const char *attributeTypeorName)
Set the input data arrays that this algorithm will process. Specifically the idx array that this algorithm will process (starting from 0) is the array on port, connection with the specified association and name or attribute type (such as SCALARS). The fieldAssociation refers to which field in the data object the array is stored. See vtkDataObject::FieldAssociations for detail.
- Type:
SetInputArrayToProcess(self, idx
- Type:
int, port
- SetInputConnection¶
-> None C++: virtual void SetInputConnection(int port,
vtkAlgorithmOutput *input)
SetInputConnection(self, input:vtkAlgorithmOutput) -> None C++: virtual void SetInputConnection(vtkAlgorithmOutput *input)
Set the connection for the given input port index. Each input port of a filter has a specific purpose. A port may have zero or more connections and the required number is specified by each filter. Setting the connection with this method removes all other connections from the port. To add more than one connection use AddInputConnection().
The input for the connection is the output port of another
filter, which is obtained with GetOutputPort(). Typical usage is
filter2->SetInputConnection(0, filter1->GetOutputPort(0)).
- SetInputConnectionByNumber¶
- int,
input:vtkAlgorithmOutput) -> None
- C++: void SetInputConnectionByNumber(int num,
vtkAlgorithmOutput *input)
- Type:
SetInputConnectionByNumber(self, num
- SetInputData¶
void SetInputData(vtkDataObject *) SetInputData(self, __a:int, __b:vtkDataObject) -> None C++: void SetInputData(int, vtkDataObject *)
Assign a data object as input. Note that this method does not establish a pipeline connection. Use SetInputConnection() to setup a pipeline connection.
- Type:
C++
- SetInputDataObject¶
- virtual void SetInputDataObject(int port,
vtkDataObject *data)
SetInputDataObject(self, data:vtkDataObject) -> None C++: virtual void SetInputDataObject(vtkDataObject *data)
Sets the data-object as an input on the given port index. Setting the input with this method removes all other connections from the port. Internally, this method creates a vtkTrivialProducer instance and sets that as the input-connection for the given port. It is safe to call this method repeatedly with the same input data object. The MTime of the vtkAlgorithm will not change unless the data object changed.
- Type:
C++
- SetMemkindDirectory¶
static void SetMemkindDirectory(const char *directoryname)
The name of a directory, ideally mounted -o dax, to memory map an extended memory space within. This must be called before any objects are constructed in the extended space. It can not be changed once setup.
- Type:
C++
- SetNumberOfInputs¶
void SetNumberOfInputs(int num)
Directly set(allocate) number of inputs, should only be used when UserManagedInputs is true.
- Type:
C++
- SetObjectName¶
virtual void SetObjectName(const std::string &objectName)
Set/get the name of this object for reporting purposes. The name appears in warning and debug messages and in the Print output. Setting the object name does not change the MTime and does not invoke a ModifiedEvent. Derived classes implementing copying methods are expected not to copy the ObjectName.
- Type:
C++
- SetOutputPointsPrecision¶
virtual void SetOutputPointsPrecision(int _arg)
Set/get the desired precision for the output types. See the documentation for the vtkAlgorithm::DesiredOutputPrecision enum for an explanation of the available precision settings.
- Type:
C++
- SetParallelStreaming¶
virtual void SetParallelStreaming(vtkTypeBool _arg)
ParallelStreaming is for a particular application. It causes this filter to ask for a different piece from each of its inputs. If all the inputs are the same, then the output of this append filter is the whole dataset pieced back together. Duplicate points are create along the seams. The purpose of this feature is to get data parallelism at a course scale. Each of the inputs can be generated in a different process at the same time.
- Type:
C++
- SetProgressObserver¶
void SetProgressObserver(vtkProgressObserver *)
If an ProgressObserver is set, the algorithm will report progress through it rather than directly. This means that it will call UpdateProgress() on the ProgressObserver rather than itself report it and set progress. This is most useful in situations where multiple threads are executing an algorithm at the same time and want to handle progress locally.
- Type:
C++
- SetProgressShiftScale¶
void SetProgressShiftScale(double shift, double scale)
Specify the shift and scale values to use to apply to the progress amount when UpdateProgress is called. By default shift is set to 0, and scale is set to 1.0. This is useful when the vtkAlgorithm instance is used as an internal algorithm to solve only a part of a whole problem.
If calling on a internal vtkAlgorithm, make sure you take into consideration that values set of the outer vtkAlgorithm as well since the outer vtkAlgorithm itself may be nested in another algorithm.
ote SetProgressShiftScale does not modify the MTime of the algorithm.
- Type:
C++
- SetProgressText¶
void SetProgressText(const char *ptext)
Set the current text message associated with the progress state. This may be used by a calling process/GUI. Note: Because SetProgressText() is called from inside RequestData() it does not modify the algorithm object. Algorithms are not allowed to modify themselves from inside RequestData().
- Type:
C++
- SetReferenceCount¶
void SetReferenceCount(int)
Sets the reference count. (This is very dangerous, use with care.)
- Type:
C++
- SetReleaseDataFlag¶
virtual void SetReleaseDataFlag(vtkTypeBool)
Turn release data flag on or off for all output ports.
- Type:
C++
- SetUserManagedInputs¶
virtual void SetUserManagedInputs(vtkTypeBool _arg)
UserManagedInputs allows the user to set inputs by number instead of using the AddInput/RemoveInput functions. Calls to SetNumberOfInputs/SetInputConnectionByNumber should not be mixed with calls to AddInput/RemoveInput. By default, UserManagedInputs is false.
- Type:
C++
- UnRegister¶
virtual void UnRegister(vtkObjectBase* o)
Decrease the reference count (release by another object). This has the same effect as invoking Delete() (i.e., it reduces the reference count by 1).
- Type:
C++
- Update¶
virtual void Update(int port) Update(self) -> None C++: virtual void Update() Update(self, port:int, requests:vtkInformationVector) -> int C++: virtual vtkTypeBool Update(int port,
vtkInformationVector *requests)
Update(self, requests:vtkInformation) -> int C++: virtual vtkTypeBool Update(vtkInformation *requests)
Bring this algorithm’s outputs up-to-date.
- Type:
C++
- UpdateDataObject¶
virtual void UpdateDataObject()
Create output object(s).
- Type:
C++
- UpdateExtent¶
virtual int UpdateExtent(const int extents[6])
Convenience method to update an algorithm after passing requests to its first output port. Supports extent request.
- Type:
C++
- UpdateExtentIsEmpty¶
- vtkInformation,
output:vtkDataObject) -> int
- C++: int UpdateExtentIsEmpty(vtkInformation *pinfo,
vtkDataObject *output)
- UpdateExtentIsEmpty(self, pinfo:vtkInformation, extentType:int)
-> int
- C++: int UpdateExtentIsEmpty(vtkInformation *pinfo,
int extentType)
This detects when the UpdateExtent will generate no data This condition is satisfied when the UpdateExtent has zero volume (0,-1,…) or the UpdateNumberOfPieces is 0. The source uses this call to determine whether to call Execute.
- Type:
UpdateExtentIsEmpty(self, pinfo
- UpdateInformation¶
virtual void UpdateInformation()
Bring the algorithm’s information up-to-date.
- Type:
C++
- UpdatePiece¶
- int, ghostLevels:int,
extents:(int, int, int, int, int, int)=…) -> int
- C++: virtual int UpdatePiece(int piece, int numPieces,
int ghostLevels, const int extents[6]=nullptr)
Convenience method to update an algorithm after passing requests to its first output port. See documentation for Update(int port, vtkInformationVector* requests) for details. Supports piece and extent (optional) requests.
- Type:
UpdatePiece(self, piece
- Type:
int, numPieces
- UpdateProgress¶
void UpdateProgress(double amount)
Update the progress of the process object. If a ProgressMethod exists, executes it. Then set the Progress ivar to amount. The parameter amount should range between (0,1).
- Type:
C++
- UpdateTimeStep¶
- int=-1, numPieces:int=1,
- ghostLevels:int=0, extents:(int, int, int, int, int, int)=…)
-> int
- C++: virtual int UpdateTimeStep(double time, int piece=-1,
int numPieces=1, int ghostLevels=0, const int extents[6]=nullptr)
Convenience method to update an algorithm after passing requests to its first output port. See documentation for Update(int port, vtkInformationVector* requests) for details. Supports time, piece (optional) and extent (optional) requests.
- Type:
UpdateTimeStep(self, time
- Type:
float, piece
- UpdateWholeExtent¶
virtual void UpdateWholeExtent()
Bring this algorithm’s outputs up-to-date.
- Type:
C++
- UserManagedInputsOff¶
virtual void UserManagedInputsOff()
- Type:
C++
- UserManagedInputsOn¶
virtual void UserManagedInputsOn()
- Type:
C++
- UsesGarbageCollector¶
bool UsesGarbageCollector() override;
Participate in garbage collection.
- Type:
C++