IntegerProgression¶
Create a raw array that contains an arithmetic progression of numbers with integer step size.
This gives the same numbers as the RangeIterator node (corresponds to the "arange" function for Python arrays). One may optionally specify a template array to determine the stop value if desired; in this case the shape of the created array will conform to that of the template array, which must be a vector. The node supports alternative compute backends, which can be used to speed up processing. Version 1.1.0
Ports/Properties¶
array¶
Output array.
- verbose name: Array
- default value: None
- port type: DataPort
- value type: AnyNumeric (can be None)
- data direction: OUT
like¶
Optional template array.
- verbose name: Like
- default value: None
- port type: DataPort
- value type: AnyNumeric (can be None)
- data direction: IN
start¶
Start value of the range.
- verbose name: Start
- default value: 0
- port type: IntPort
- value type: int (can be None)
stop¶
End value of the range, must be provided. Not included in the range unless the inclusive option is set to True. If an array or list has been wired into the 'like' input of the node, then the stop value may be omitted and will be inferred from the length of that array.
- verbose name: Stop
- default value: None
- port type: IntPort
- value type: int (can be None)
step¶
Step size of the range.
- verbose name: Step
- default value: 1
- port type: IntPort
- value type: int (can be None)
inclusive¶
Whether the stop value is inclusive or exclusive. If the start and step values are chosen such that the range cannot include the stop value (i.e., will miss it), then an error is raised if this is enabled.
- verbose name: Inclusive
- default value: False
- port type: BoolPort
- value type: bool (can be None)
backend¶
Optional compute backend to use. Keep is the current default, which resolves to that of the template array if one is provided and otherwise numpy unless overridden. Numpy is the standard CPU backend that underpins most of NeuroPype's operations. The others require one or more GPUs to be present on the system, except for torch-cpu. For best performance, keep all arrays that interact with each other (via processing nodes) on the same backend.
- verbose name: Backend
- default value: keep
- port type: EnumPort
- value type: str (can be None)
precision¶
Numeric precision to use. Keep resolves to the precision of the template array if one is provided, and otherwise to the current default (usually 64-bit). Can be reduced to save memory (e.g. if running on GPU).
- verbose name: Precision
- default value: keep
- port type: EnumPort
- value type: str (can be None)
set_breakpoint¶
Set a breakpoint on this node. If this is enabled, your debugger (if one is attached) will trigger a breakpoint.
- verbose name: Set Breakpoint (Debug Only)
- default value: False
- port type: BoolPort
- value type: bool (can be None)
metadata¶
User-definable meta-data associated with the node. Usually reserved for technical purposes.
- verbose name: Metadata
- default value: {}
- port type: DictPort
- value type: dict (can be None)