holoscan.conditions
This module provides a Python API to underlying C++ API Conditions.
holoscan.conditions.AsynchronousCondition |
Asynchronous condition class. |
holoscan.conditions.BooleanCondition |
Boolean condition. |
holoscan.conditions.CountCondition |
Count condition. |
holoscan.conditions.DownstreamMessageAffordableCondition |
Condition that permits execution when the downstream operator can accept new messages. |
holoscan.conditions.ExpiringMessageAvailableCondition |
Condition that tries to wait for specified number of messages in receiver. |
holoscan.conditions.MessageAvailableCondition |
Condition that permits execution when an upstream message is available. |
holoscan.conditions.PeriodicCondition |
Condition class to support periodic execution of operators. |
- class holoscan.conditions.AsynchronousCondition
Bases:
holoscan.gxf._gxf.GXFCondition
Asynchronous condition class.
Used to control whether an entity is executed.
Attributes
args
The list of arguments associated with the component. description
YAML formatted string describing the condition. event_state
Event state property fragment
Fragment that the condition belongs to. gxf_cid
The GXF component ID. gxf_cname
The name of the component. gxf_context
The GXF context of the component. gxf_eid
The GXF entity ID. gxf_typename
The GXF type name of the component. id
The identifier of the component. name
The name of the condition. spec Methods
add_arg
(*args, **kwargs)Overloaded function. gxf_initialize
(self)Initialize the component. initialize
(self)initialization method for the condition. setup
(self, arg0)setup method for the condition. - __init__(self: holoscan.conditions._conditions.AsynchronousCondition, fragment: holoscan.core._core.Fragment, name: str = 'noname_async_condition') → None
Asynchronous condition.
- Parameters
- fragmentholoscan.core.Fragment
The fragment the condition will be associated with
- namestr, optional
The name of the condition.
- add_arg(*args, **kwargs)
Overloaded function.
add_arg(self: holoscan.core._core.ComponentBase, arg: holoscan.core._core.Arg) -> None
Add an argument to the component.
add_arg(self: holoscan.core._core.ComponentBase, arg: holoscan.core._core.ArgList) -> None
Add a list of arguments to the component.
- property args
The list of arguments associated with the component.
- Returns
- arglistholoscan.core.ArgList
- property description
YAML formatted string describing the condition.
- property event_state
Event state property
AsynchronousEventState.READY
AsynchronousEventState.WAIT
AsynchronousEventState.EVENT_WAITING
AsynchronousEventState.EVENT_DONE
AsynchronousEventState.EVENT_NEVER
- property fragment
Fragment that the condition belongs to.
- Returns
- nameholoscan.core.Fragment
- property gxf_cid
The GXF component ID.
- property gxf_cname
The name of the component.
- property gxf_context
The GXF context of the component.
- property gxf_eid
The GXF entity ID.
- gxf_initialize(self: holoscan.gxf._gxf.GXFComponent) → None
Initialize the component.
- property gxf_typename
The GXF type name of the component.
- Returns
- str
The GXF type name of the component.
- property id
The identifier of the component.
The identifier is initially set to
-1
, and will become a valid value when the component is initialized.With the default executor (holoscan.gxf.GXFExecutor), the identifier is set to the GXF component ID.
- Returns
- idint
- initialize(self: holoscan.core._core.Condition) → None
initialization method for the condition.
- property name
The name of the condition.
- Returns
- namestr
- setup(self: holoscan.core._core.Condition, arg0: holoscan.core._core.ComponentSpec) → None
setup method for the condition.
- property spec
- class holoscan.conditions.AsynchronousEventState
Bases:
pybind11_builtins.pybind11_object
Members:
READY
WAIT
EVENT_WAITING
EVENT_DONE
EVENT_NEVER
Attributes
name
value - EVENT_DONE = <AsynchronousEventState.EVENT_DONE: 3>
- EVENT_NEVER = <AsynchronousEventState.EVENT_NEVER: 4>
- EVENT_WAITING = <AsynchronousEventState.EVENT_WAITING: 2>
- READY = <AsynchronousEventState.READY: 0>
- WAIT = <AsynchronousEventState.WAIT: 1>
- __init__(self: holoscan.conditions._conditions.AsynchronousEventState, value: int) → None
- property name
- property value
- class holoscan.conditions.BooleanCondition
Bases:
holoscan.gxf._gxf.GXFCondition
Boolean condition.
- Parameters
- fragmentholoscan.core.Fragment
The fragment the condition will be associated with
- enable_tickbool, optional
Boolean value for the condition.
- namestr, optional
The name of the condition.
Attributes
args
The list of arguments associated with the component. description
YAML formatted string describing the condition. fragment
Fragment that the condition belongs to. gxf_cid
The GXF component ID. gxf_cname
The name of the component. gxf_context
The GXF context of the component. gxf_eid
The GXF entity ID. gxf_typename
The GXF type name of the component. id
The identifier of the component. name
The name of the condition. spec Methods
add_arg
(*args, **kwargs)Overloaded function. check_tick_enabled
(self)Check whether the condition is True
.disable_tick
(self)Set condition to False
.enable_tick
(self)Set condition to True
.gxf_initialize
(self)Initialize the component. initialize
(self)initialization method for the condition. setup
(self, arg0)setup method for the condition. - __init__(self: holoscan.conditions._conditions.BooleanCondition, fragment: holoscan.core._core.Fragment, enable_tick: bool = True, name: str = 'noname_boolean_condition') → None
Boolean condition.
- Parameters
- fragmentholoscan.core.Fragment
The fragment the condition will be associated with
- enable_tickbool, optional
Boolean value for the condition.
- namestr, optional
The name of the condition.
- add_arg(*args, **kwargs)
Overloaded function.
add_arg(self: holoscan.core._core.ComponentBase, arg: holoscan.core._core.Arg) -> None
Add an argument to the component.
add_arg(self: holoscan.core._core.ComponentBase, arg: holoscan.core._core.ArgList) -> None
Add a list of arguments to the component.
- property args
The list of arguments associated with the component.
- Returns
- arglistholoscan.core.ArgList
- check_tick_enabled(self: holoscan.conditions._conditions.BooleanCondition) → bool
Check whether the condition is
True
.
- property description
YAML formatted string describing the condition.
- disable_tick(self: holoscan.conditions._conditions.BooleanCondition) → None
Set condition to
False
.
- enable_tick(self: holoscan.conditions._conditions.BooleanCondition) → None
Set condition to
True
.
- property fragment
Fragment that the condition belongs to.
- Returns
- nameholoscan.core.Fragment
- property gxf_cid
The GXF component ID.
- property gxf_cname
The name of the component.
- property gxf_context
The GXF context of the component.
- property gxf_eid
The GXF entity ID.
- gxf_initialize(self: holoscan.gxf._gxf.GXFComponent) → None
Initialize the component.
- property gxf_typename
The GXF type name of the component.
- Returns
- str
The GXF type name of the component.
- property id
The identifier of the component.
The identifier is initially set to
-1
, and will become a valid value when the component is initialized.With the default executor (holoscan.gxf.GXFExecutor), the identifier is set to the GXF component ID.
- Returns
- idint
- initialize(self: holoscan.core._core.Condition) → None
initialization method for the condition.
- property name
The name of the condition.
- Returns
- namestr
- setup(self: holoscan.core._core.Condition, arg0: holoscan.core._core.ComponentSpec) → None
setup method for the condition.
- property spec
- class holoscan.conditions.CountCondition
Bases:
holoscan.gxf._gxf.GXFCondition
Count condition.
- Parameters
- fragmentholoscan.core.Fragment
The fragment the condition will be associated with
- countint
The execution count value used by the condition.
- namestr, optional
The name of the condition.
Attributes
args
The list of arguments associated with the component. count
The execution count associated with the condition description
YAML formatted string describing the condition. fragment
Fragment that the condition belongs to. gxf_cid
The GXF component ID. gxf_cname
The name of the component. gxf_context
The GXF context of the component. gxf_eid
The GXF entity ID. gxf_typename
The GXF type name of the component. id
The identifier of the component. name
The name of the condition. spec Methods
add_arg
(*args, **kwargs)Overloaded function. gxf_initialize
(self)Initialize the component. initialize
(self)initialization method for the condition. setup
(self, arg0)setup method for the condition. - __init__(self: holoscan.conditions._conditions.CountCondition, fragment: holoscan.core._core.Fragment, count: int = 1, name: str = 'noname_count_condition') → None
Count condition.
- Parameters
- fragmentholoscan.core.Fragment
The fragment the condition will be associated with
- countint
The execution count value used by the condition.
- namestr, optional
The name of the condition.
- add_arg(*args, **kwargs)
Overloaded function.
add_arg(self: holoscan.core._core.ComponentBase, arg: holoscan.core._core.Arg) -> None
Add an argument to the component.
add_arg(self: holoscan.core._core.ComponentBase, arg: holoscan.core._core.ArgList) -> None
Add a list of arguments to the component.
- property args
The list of arguments associated with the component.
- Returns
- arglistholoscan.core.ArgList
- property count
The execution count associated with the condition
- property description
YAML formatted string describing the condition.
- property fragment
Fragment that the condition belongs to.
- Returns
- nameholoscan.core.Fragment
- property gxf_cid
The GXF component ID.
- property gxf_cname
The name of the component.
- property gxf_context
The GXF context of the component.
- property gxf_eid
The GXF entity ID.
- gxf_initialize(self: holoscan.gxf._gxf.GXFComponent) → None
Initialize the component.
- property gxf_typename
The GXF type name of the component.
- Returns
- str
The GXF type name of the component.
- property id
The identifier of the component.
The identifier is initially set to
-1
, and will become a valid value when the component is initialized.With the default executor (holoscan.gxf.GXFExecutor), the identifier is set to the GXF component ID.
- Returns
- idint
- initialize(self: holoscan.core._core.Condition) → None
initialization method for the condition.
- property name
The name of the condition.
- Returns
- namestr
- setup(self: holoscan.core._core.Condition, arg0: holoscan.core._core.ComponentSpec) → None
setup method for the condition.
- property spec
- class holoscan.conditions.DownstreamMessageAffordableCondition
Bases:
holoscan.gxf._gxf.GXFCondition
Condition that permits execution when the downstream operator can accept new messages.
Satisfied when the receiver queue of any connected downstream operators has at least a certain number of elements free. The minimum number of messages that permits the execution of the entity is specified by min_size. It can be used for operators to prevent operators from sending a message when the downstream operator is not ready to receive it.
- Parameters
- fragmentholoscan.core.Fragment
The fragment the condition will be associated with
- min_sizeint
The minimum number of free slots present in the back buffer.
- namestr, optional
The name of the condition.
Attributes
args
The list of arguments associated with the component. description
YAML formatted string describing the condition. fragment
Fragment that the condition belongs to. gxf_cid
The GXF component ID. gxf_cname
The name of the component. gxf_context
The GXF context of the component. gxf_eid
The GXF entity ID. gxf_typename
The GXF type name of the component. id
The identifier of the component. min_size
The minimum number of free slots required for the downstream entity's back buffer. name
The name of the condition. transmitter
The transmitter associated with the condition. spec Methods
add_arg
(*args, **kwargs)Overloaded function. gxf_initialize
(self)Initialize the component. initialize
(self)initialization method for the condition. setup
(self, arg0)setup method for the condition. - __init__(self: holoscan.conditions._conditions.DownstreamMessageAffordableCondition, fragment: holoscan.core._core.Fragment, min_size: int = 1, name: str = 'noname_downstream_affordable_condition') → None
Condition that permits execution when the downstream operator can accept new messages.
Satisfied when the receiver queue of any connected downstream operators has at least a certain number of elements free. The minimum number of messages that permits the execution of the entity is specified by min_size. It can be used for operators to prevent operators from sending a message when the downstream operator is not ready to receive it.
- Parameters
- fragmentholoscan.core.Fragment
The fragment the condition will be associated with
- min_sizeint
The minimum number of free slots present in the back buffer.
- namestr, optional
The name of the condition.
- add_arg(*args, **kwargs)
Overloaded function.
add_arg(self: holoscan.core._core.ComponentBase, arg: holoscan.core._core.Arg) -> None
Add an argument to the component.
add_arg(self: holoscan.core._core.ComponentBase, arg: holoscan.core._core.ArgList) -> None
Add a list of arguments to the component.
- property args
The list of arguments associated with the component.
- Returns
- arglistholoscan.core.ArgList
- property description
YAML formatted string describing the condition.
- property fragment
Fragment that the condition belongs to.
- Returns
- nameholoscan.core.Fragment
- property gxf_cid
The GXF component ID.
- property gxf_cname
The name of the component.
- property gxf_context
The GXF context of the component.
- property gxf_eid
The GXF entity ID.
- gxf_initialize(self: holoscan.gxf._gxf.GXFComponent) → None
Initialize the component.
- property gxf_typename
The GXF type name of the component.
- Returns
- str
The GXF type name of the component.
- property id
The identifier of the component.
The identifier is initially set to
-1
, and will become a valid value when the component is initialized.With the default executor (holoscan.gxf.GXFExecutor), the identifier is set to the GXF component ID.
- Returns
- idint
- initialize(self: holoscan.core._core.Condition) → None
initialization method for the condition.
- property min_size
The minimum number of free slots required for the downstream entity’s back buffer.
- property name
The name of the condition.
- Returns
- namestr
- setup(self: holoscan.core._core.Condition, arg0: holoscan.core._core.ComponentSpec) → None
setup method for the condition.
- property spec
- property transmitter
The transmitter associated with the condition.
- class holoscan.conditions.ExpiringMessageAvailableCondition
Bases:
holoscan.gxf._gxf.GXFCondition
Condition that tries to wait for specified number of messages in receiver. When the first message in the queue mature after specified delay since arrival it would fire regardless.
- Parameters
- fragmentholoscan.core.Fragment
The fragment the condition will be associated with
- max_batch_sizeint
The maximum number of messages to be batched together.
- max_delay_ns: int or datetime.timedelta
The maximum delay to wait from the time of the first message before submitting the workload anyway. If an int is provided, the value must be in nanoseconds. Any provided datetime.timedelta value will be converted internally to the corresponding number of nanoseconds to wait.
- clockholoscan.resources.Clock or None, optional
The clock used by the scheduler to define the flow of time. If None, a default-constructed holoscan.resources.RealtimeClock will be used.
- namestr, optional
The name of the condition.
Attributes
args
The list of arguments associated with the component. description
YAML formatted string describing the condition. fragment
Fragment that the condition belongs to. gxf_cid
The GXF component ID. gxf_cname
The name of the component. gxf_context
The GXF context of the component. gxf_eid
The GXF entity ID. gxf_typename
The GXF type name of the component. id
The identifier of the component. max_batch_size
The maximum number of messages to be batched together. name
The name of the condition. receiver
The receiver associated with the condition. spec Methods
add_arg
(*args, **kwargs)Overloaded function. gxf_initialize
(self)Initialize the component. initialize
(self)initialization method for the condition. max_delay
(*args, **kwargs)Overloaded function. max_delay_ns
(self)The maximum delay from first message to wait before submitting workload anyway. setup
(self, arg0)setup method for the condition. - __init__(*args, **kwargs)
Overloaded function.
__init__(self: holoscan.conditions._conditions.ExpiringMessageAvailableCondition, fragment: holoscan.core._core.Fragment, max_batch_size: int, max_delay_ns: int, clock: holoscan::Clock = None, name: str = ‘noname_expiring_message_available_condition’) -> None
__init__(self: holoscan.conditions._conditions.ExpiringMessageAvailableCondition, fragment: holoscan.core._core.Fragment, max_batch_size: int, max_delay_ns: datetime.timedelta, clock: holoscan::Clock = None, name: str = ‘noname_expiring_message_available_condition’) -> None
Condition that tries to wait for specified number of messages in receiver. When the first message in the queue mature after specified delay since arrival it would fire regardless.
- Parameters
- fragmentholoscan.core.Fragment
The fragment the condition will be associated with
- max_batch_sizeint
The maximum number of messages to be batched together.
- max_delay_ns: int or datetime.timedelta
The maximum delay to wait from the time of the first message before submitting the workload anyway. If an int is provided, the value must be in nanoseconds. Any provided datetime.timedelta value will be converted internally to the corresponding number of nanoseconds to wait.
- clockholoscan.resources.Clock or None, optional
The clock used by the scheduler to define the flow of time. If None, a default-constructed holoscan.resources.RealtimeClock will be used.
- namestr, optional
The name of the condition.
- add_arg(*args, **kwargs)
Overloaded function.
add_arg(self: holoscan.core._core.ComponentBase, arg: holoscan.core._core.Arg) -> None
Add an argument to the component.
add_arg(self: holoscan.core._core.ComponentBase, arg: holoscan.core._core.ArgList) -> None
Add a list of arguments to the component.
- property args
The list of arguments associated with the component.
- Returns
- arglistholoscan.core.ArgList
- property description
YAML formatted string describing the condition.
- property fragment
Fragment that the condition belongs to.
- Returns
- nameholoscan.core.Fragment
- property gxf_cid
The GXF component ID.
- property gxf_cname
The name of the component.
- property gxf_context
The GXF context of the component.
- property gxf_eid
The GXF entity ID.
- gxf_initialize(self: holoscan.gxf._gxf.GXFComponent) → None
Initialize the component.
- property gxf_typename
The GXF type name of the component.
- Returns
- str
The GXF type name of the component.
- property id
The identifier of the component.
The identifier is initially set to
-1
, and will become a valid value when the component is initialized.With the default executor (holoscan.gxf.GXFExecutor), the identifier is set to the GXF component ID.
- Returns
- idint
- initialize(self: holoscan.core._core.Condition) → None
initialization method for the condition.
- property max_batch_size
The maximum number of messages to be batched together.
- max_delay(*args, **kwargs)
Overloaded function.
max_delay(self: holoscan.conditions._conditions.ExpiringMessageAvailableCondition, arg0: int) -> None
The maximum delay from first message to wait before submitting workload anyway.
max_delay(self: holoscan.conditions._conditions.ExpiringMessageAvailableCondition, arg0: datetime.timedelta) -> None
The maximum delay from first message to wait before submitting workload anyway.
- max_delay_ns(self: holoscan.conditions._conditions.ExpiringMessageAvailableCondition) → int
The maximum delay from first message to wait before submitting workload anyway.
- property name
The name of the condition.
- Returns
- namestr
- property receiver
The receiver associated with the condition.
- setup(self: holoscan.core._core.Condition, arg0: holoscan.core._core.ComponentSpec) → None
setup method for the condition.
- property spec
- class holoscan.conditions.MessageAvailableCondition
Bases:
holoscan.gxf._gxf.GXFCondition
Condition that permits execution when an upstream message is available.
Satisfied when the associated receiver queue has at least a certain number of elements. The receiver is specified using the receiver parameter of the scheduling term. The minimum number of messages that permits the execution of the entity is specified by min_size. An optional parameter for this scheduling term is front_stage_max_size, the maximum front stage message count. If this parameter is set, the scheduling term will only allow execution if the number of messages in the queue does not exceed this count. It can be used for operators which do not consume all messages from the queue.
- Parameters
- fragmentholoscan.core.Fragment
The fragment the condition will be associated with
- min_sizeint
The total number of messages over a set of input channels needed to permit execution.
- front_stage_max_sizeint
Threshold for the number of front stage messages. Execution is only allowed if the number of front stage messages does not exceed this count.
- namestr, optional
The name of the condition.
Attributes
args
The list of arguments associated with the component. description
YAML formatted string describing the condition. fragment
Fragment that the condition belongs to. front_stage_max_size
Threshold for the number of front stage messages. gxf_cid
The GXF component ID. gxf_cname
The name of the component. gxf_context
The GXF context of the component. gxf_eid
The GXF entity ID. gxf_typename
The GXF type name of the component. id
The identifier of the component. min_size
The total number of messages over a set of input channels needed to permit execution. name
The name of the condition. receiver
The receiver associated with the condition. spec Methods
add_arg
(*args, **kwargs)Overloaded function. gxf_initialize
(self)Initialize the component. initialize
(self)initialization method for the condition. setup
(self, arg0)setup method for the condition. - __init__(self: holoscan.conditions._conditions.MessageAvailableCondition, fragment: holoscan.core._core.Fragment, min_size: int = 1, front_stage_max_size: int = 1, name: str = 'noname_message_available_condition') → None
Condition that permits execution when an upstream message is available.
Satisfied when the associated receiver queue has at least a certain number of elements. The receiver is specified using the receiver parameter of the scheduling term. The minimum number of messages that permits the execution of the entity is specified by min_size. An optional parameter for this scheduling term is front_stage_max_size, the maximum front stage message count. If this parameter is set, the scheduling term will only allow execution if the number of messages in the queue does not exceed this count. It can be used for operators which do not consume all messages from the queue.
- Parameters
- fragmentholoscan.core.Fragment
The fragment the condition will be associated with
- min_sizeint
The total number of messages over a set of input channels needed to permit execution.
- front_stage_max_sizeint
Threshold for the number of front stage messages. Execution is only allowed if the number of front stage messages does not exceed this count.
- namestr, optional
The name of the condition.
- add_arg(*args, **kwargs)
Overloaded function.
add_arg(self: holoscan.core._core.ComponentBase, arg: holoscan.core._core.Arg) -> None
Add an argument to the component.
add_arg(self: holoscan.core._core.ComponentBase, arg: holoscan.core._core.ArgList) -> None
Add a list of arguments to the component.
- property args
The list of arguments associated with the component.
- Returns
- arglistholoscan.core.ArgList
- property description
YAML formatted string describing the condition.
- property fragment
Fragment that the condition belongs to.
- Returns
- nameholoscan.core.Fragment
- property front_stage_max_size
Threshold for the number of front stage messages. Execution is only allowed if the number of front stage messages does not exceed this count.
- property gxf_cid
The GXF component ID.
- property gxf_cname
The name of the component.
- property gxf_context
The GXF context of the component.
- property gxf_eid
The GXF entity ID.
- gxf_initialize(self: holoscan.gxf._gxf.GXFComponent) → None
Initialize the component.
- property gxf_typename
The GXF type name of the component.
- Returns
- str
The GXF type name of the component.
- property id
The identifier of the component.
The identifier is initially set to
-1
, and will become a valid value when the component is initialized.With the default executor (holoscan.gxf.GXFExecutor), the identifier is set to the GXF component ID.
- Returns
- idint
- initialize(self: holoscan.core._core.Condition) → None
initialization method for the condition.
- property min_size
The total number of messages over a set of input channels needed to permit execution.
- property name
The name of the condition.
- Returns
- namestr
- property receiver
The receiver associated with the condition.
- setup(self: holoscan.core._core.Condition, arg0: holoscan.core._core.ComponentSpec) → None
setup method for the condition.
- property spec
- class holoscan.conditions.PeriodicCondition
Bases:
holoscan.gxf._gxf.GXFCondition
Condition class to support periodic execution of operators. The recess (pause) period indicates the minimum amount of time that must elapse before the compute() method can be executed again. The recess period can be specified as an integer value in nanoseconds.
For example: 1000 for 1 microsecond 1000000 for 1 millisecond, and 10000000000 for 1 second.
The recess (pause) period can also be specified as a datetime.timedelta object representing a duration. (see https://docs.python.org/3/library/datetime.html#timedelta-objects)
For example: datetime.timedelta(minutes=1), datetime.timedelta(seconds=1), datetime.timedelta(milliseconds=1) and datetime.timedelta(microseconds=1). Supported argument names are: weeks| days | hours | minutes | seconds | millisecons | microseconds This requires import datetime.
- Parameters
- fragmentholoscan.core.Fragment
The fragment the condition will be associated with
- recess_periodint or datetime.timedelta
The recess (pause) period value used by the condition. If an integer is provided, the units are in nanoseconds.
- namestr, optional
The name of the condition.
Attributes
args
The list of arguments associated with the component. description
YAML formatted string describing the condition. fragment
Fragment that the condition belongs to. gxf_cid
The GXF component ID. gxf_cname
The name of the component. gxf_context
The GXF context of the component. gxf_eid
The GXF entity ID. gxf_typename
The GXF type name of the component. id
The identifier of the component. name
The name of the condition. spec Methods
add_arg
(*args, **kwargs)Overloaded function. gxf_initialize
(self)Initialize the component. initialize
(self)initialization method for the condition. last_run_timestamp
(self)Gets the integer representing the last run time stamp. recess_period
(*args, **kwargs)Overloaded function. recess_period_ns
(self)Gets the recess (pause) period value in nanoseconds. setup
(self, arg0)setup method for the condition. - __init__(*args, **kwargs)
Overloaded function.
__init__(self: holoscan.conditions._conditions.PeriodicCondition, fragment: holoscan.core._core.Fragment, recess_period: int, name: str = ‘noname_periodic_condition’) -> None
__init__(self: holoscan.conditions._conditions.PeriodicCondition, fragment: holoscan.core._core.Fragment, recess_period: datetime.timedelta, name: str = ‘noname_periodic_condition’) -> None
Condition class to support periodic execution of operators. The recess (pause) period indicates the minimum amount of time that must elapse before the compute() method can be executed again. The recess period can be specified as an integer value in nanoseconds.
For example: 1000 for 1 microsecond 1000000 for 1 millisecond, and 10000000000 for 1 second.
The recess (pause) period can also be specified as a datetime.timedelta object representing a duration. (see https://docs.python.org/3/library/datetime.html#timedelta-objects)
For example: datetime.timedelta(minutes=1), datetime.timedelta(seconds=1), datetime.timedelta(milliseconds=1) and datetime.timedelta(microseconds=1). Supported argument names are: weeks| days | hours | minutes | seconds | millisecons | microseconds This requires import datetime.
- Parameters
- fragmentholoscan.core.Fragment
The fragment the condition will be associated with
- recess_periodint or datetime.timedelta
The recess (pause) period value used by the condition. If an integer is provided, the units are in nanoseconds.
- namestr, optional
The name of the condition.
- add_arg(*args, **kwargs)
Overloaded function.
add_arg(self: holoscan.core._core.ComponentBase, arg: holoscan.core._core.Arg) -> None
Add an argument to the component.
add_arg(self: holoscan.core._core.ComponentBase, arg: holoscan.core._core.ArgList) -> None
Add a list of arguments to the component.
- property args
The list of arguments associated with the component.
- Returns
- arglistholoscan.core.ArgList
- property description
YAML formatted string describing the condition.
- property fragment
Fragment that the condition belongs to.
- Returns
- nameholoscan.core.Fragment
- property gxf_cid
The GXF component ID.
- property gxf_cname
The name of the component.
- property gxf_context
The GXF context of the component.
- property gxf_eid
The GXF entity ID.
- gxf_initialize(self: holoscan.gxf._gxf.GXFComponent) → None
Initialize the component.
- property gxf_typename
The GXF type name of the component.
- Returns
- str
The GXF type name of the component.
- property id
The identifier of the component.
The identifier is initially set to
-1
, and will become a valid value when the component is initialized.With the default executor (holoscan.gxf.GXFExecutor), the identifier is set to the GXF component ID.
- Returns
- idint
- initialize(self: holoscan.core._core.Condition) → None
initialization method for the condition.
- last_run_timestamp(self: holoscan.conditions._conditions.PeriodicCondition) → int
Gets the integer representing the last run time stamp.
- property name
The name of the condition.
- Returns
- namestr
- recess_period(*args, **kwargs)
Overloaded function.
recess_period(self: holoscan.conditions._conditions.PeriodicCondition, arg0: int) -> None
Sets the recess (pause) period associated with the condition. The recess period can be specified as an integer value in nanoseconds or a datetime.timedelta object representing a duration.
recess_period(self: holoscan.conditions._conditions.PeriodicCondition, arg0: datetime.timedelta) -> None
Sets the recess (pause) period associated with the condition. The recess period can be specified as an integer value in nanoseconds or a datetime.timedelta object representing a duration.
- recess_period_ns(self: holoscan.conditions._conditions.PeriodicCondition) → int
Gets the recess (pause) period value in nanoseconds.
- setup(self: holoscan.core._core.Condition, arg0: holoscan.core._core.ComponentSpec) → None
setup method for the condition.
- property spec