monai.deploy.operators.ClaraVizOperator

class monai.deploy.operators.ClaraVizOperator(fragement, *args, **kwargs)[source]

Bases: holoscan.core.Operator

This operator uses Clara Viz to provide interactive view of a 3D volume including segmentation mask.

Named input(s):

image: Image object of the input image, including key metadata, e.g. pixel spacings and orientations. seg_image: Image object of the segmentation image derived from the input image.

Constructor of the operator.

Parameters

fragment (Fragment) – An instance of the Application class which is derived from Fragment.

Methods

__init__(fragement, *args, **kwargs)

Constructor of the operator.

add_arg(*args, **kwargs)

Overloaded function.

compute(op_input, op_output, context)

Displays the input image and segmentation mask

initialize()

Default implementation of initialize

resource(self, name)

Resources associated with the operator.

setup(spec)

Default implementation of setup method.

start()

Default implementation of start

stop()

Default implementation of stop

Attributes

args

The list of arguments associated with the component.

conditions

Conditions associated with the operator.

description

YAML formatted string describing the operator.

fragment

The fragment (holoscan.core.Fragment) that the operator belongs to.

id

The identifier of the component.

name

The name of the operator.

operator_type

The operator type.

resources

Resources associated with the operator.

spec

The operator spec (holoscan.core.OperatorSpec) associated with the operator.

class OperatorType(self: holoscan.core._core.Operator.OperatorType, value: int) None

Bases: pybind11_builtins.pybind11_object

Enum class for operator types used by the executor.

  • NATIVE: Native operator.

  • GXF: GXF operator.

  • VIRTUAL: Virtual operator. (for internal use, not intended for use by application authors)

Members:

NATIVE

GXF

VIRTUAL

property name
__init__(fragement, *args, **kwargs)[source]

Constructor of the operator.

Parameters

fragment (Fragment) – An instance of the Application class which is derived from Fragment.

add_arg(*args, **kwargs)

Overloaded function.

  1. add_arg(self: holoscan.core._core.Operator, arg: holoscan.core._core.Arg) -> None

Add an argument to the component.

  1. add_arg(self: holoscan.core._core.Operator, arg: holoscan.core._core.ArgList) -> None

Add a list of arguments to the component.

  1. add_arg(self: holoscan.core._core.Operator, **kwargs) -> None

Add arguments to the component via Python kwargs.

  1. add_arg(self: holoscan.core._core.Operator, arg: holoscan.core._core.Condition) -> None

  2. add_arg(self: holoscan.core._core.Operator, arg: holoscan.core._core.Resource) -> None

Add a condition or resource to the Operator.

This can be used to add a condition or resource to an operator after it has already been constructed.

argholoscan.core.Condition or holoscan.core.Resource

The condition or resource to add.

property args

The list of arguments associated with the component.

arglist : holoscan.core.ArgList

compute(op_input, op_output, context)[source]

Displays the input image and segmentation mask

Parameters
  • op_input (InputContext) – An input context for the operator.

  • op_output (OutputContext) – An output context for the operator.

  • context (ExecutionContext) – An execution context for the operator.

property conditions

Conditions associated with the operator.

property description

YAML formatted string describing the operator.

property fragment

The fragment (holoscan.core.Fragment) that the operator belongs to.

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.

id : int

initialize()

Default implementation of initialize

property name

The name of the operator.

property operator_type

The operator type.

holoscan.core.Operator.OperatorType enum representing the type of the operator. The two types currently implemented are native and GXF.

resource(self: holoscan.core._core.Operator, name: str) Optional[object]

Resources associated with the operator.

name : str The name of the resource to retrieve

holoscan.core.Resource or None

The resource with the given name. If no resource with the given name is found, None is returned.

property resources

Resources associated with the operator.

setup(spec)[source]

Default implementation of setup method.

property spec

The operator spec (holoscan.core.OperatorSpec) associated with the operator.

start()

Default implementation of start

stop()

Default implementation of stop