holoscan 3.5.0__cp313-cp313-manylinux_2_35_aarch64.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- holoscan-3.5.0.data/purelib/holoscan/__init__.py +135 -0
- holoscan-3.5.0.data/purelib/holoscan/cli/__main__.py +26 -0
- holoscan-3.5.0.data/purelib/holoscan/conditions/__init__.py +75 -0
- holoscan-3.5.0.data/purelib/holoscan/conditions/_conditions.cpython-313-aarch64-linux-gnu.so +0 -0
- holoscan-3.5.0.data/purelib/holoscan/core/__init__.py +793 -0
- holoscan-3.5.0.data/purelib/holoscan/core/_core.cpython-313-aarch64-linux-gnu.so +0 -0
- holoscan-3.5.0.data/purelib/holoscan/data_loggers/__init__.py +76 -0
- holoscan-3.5.0.data/purelib/holoscan/data_loggers/async_console_logger/__init__.py +22 -0
- holoscan-3.5.0.data/purelib/holoscan/data_loggers/async_console_logger/_async_console_logger.cpython-313-aarch64-linux-gnu.so +0 -0
- holoscan-3.5.0.data/purelib/holoscan/data_loggers/basic_console_logger/__init__.py +22 -0
- holoscan-3.5.0.data/purelib/holoscan/data_loggers/basic_console_logger/_basic_console_logger.cpython-313-aarch64-linux-gnu.so +0 -0
- holoscan-3.5.0.data/purelib/holoscan/decorator.py +662 -0
- holoscan-3.5.0.data/purelib/holoscan/executors/__init__.py +26 -0
- holoscan-3.5.0.data/purelib/holoscan/executors/_executors.cpython-313-aarch64-linux-gnu.so +0 -0
- holoscan-3.5.0.data/purelib/holoscan/graphs/__init__.py +32 -0
- holoscan-3.5.0.data/purelib/holoscan/graphs/_graphs.cpython-313-aarch64-linux-gnu.so +0 -0
- holoscan-3.5.0.data/purelib/holoscan/gxf/__init__.py +60 -0
- holoscan-3.5.0.data/purelib/holoscan/gxf/_gxf.cpython-313-aarch64-linux-gnu.so +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/gxf_extensions/libgxf_holoscan_wrapper.so +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/gxf_extensions/libgxf_holoscan_wrapper_lib.so +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/gxf_extensions/libgxf_ucx_holoscan.so +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/gxf_extensions/libgxf_ucx_holoscan_lib.so +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/libgxf_app.so +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/libgxf_core.so +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/libgxf_cuda.so +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/libgxf_http.so +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/libgxf_logger.so +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/libgxf_multimedia.so +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/libgxf_rmm.so +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/libgxf_sample.so +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/libgxf_serialization.so +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/libgxf_std.so +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/libgxf_ucx.so +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/libholoscan_core.so.3.5.0 +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/libholoscan_data_loggers_async_console_logger.so.3.5.0 +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/libholoscan_data_loggers_basic_console_logger.so.3.5.0 +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/libholoscan_infer.so.3.5.0 +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/libholoscan_infer_onnx_runtime.so.3.5.0 +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/libholoscan_infer_torch.so.3.5.0 +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/libholoscan_infer_utils.so.3.5.0 +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/libholoscan_logger.so.3.5.0 +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/libholoscan_op_async_ping_rx.so.3.5.0 +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/libholoscan_op_async_ping_tx.so.3.5.0 +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/libholoscan_op_bayer_demosaic.so.3.5.0 +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/libholoscan_op_format_converter.so.3.5.0 +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/libholoscan_op_gxf_codelet.so.3.5.0 +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/libholoscan_op_holoviz.so.3.5.0 +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/libholoscan_op_inference.so.3.5.0 +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/libholoscan_op_inference_processor.so.3.5.0 +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/libholoscan_op_ping_rx.so.3.5.0 +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/libholoscan_op_ping_tensor_rx.so.3.5.0 +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/libholoscan_op_ping_tensor_tx.so.3.5.0 +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/libholoscan_op_ping_tx.so.3.5.0 +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/libholoscan_op_segmentation_postprocessor.so.3.5.0 +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/libholoscan_op_v4l2.so.3.5.0 +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/libholoscan_op_video_stream_recorder.so.3.5.0 +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/libholoscan_op_video_stream_replayer.so.3.5.0 +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/libholoscan_pose_tree.so.3.5.0 +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/libholoscan_profiler.so.3.5.0 +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/libholoscan_spdlog_logger.so.3.5.0 +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/libholoscan_viz.so.3.5.0 +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/libucm.so.0.0.0 +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/libucp.so.0.0.0 +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/libucs.so.0.0.0 +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/libucs_signal.so.0.0.0 +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/libuct.so.0.0.0 +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/libucxx.so +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/ucx/libucm_cuda.so.0.0.0 +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/ucx/libucs_fuse.so.0.0.0 +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/ucx/libuct_cma.so.0.0.0 +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/ucx/libuct_cuda.so.0.0.0 +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/ucx/libuct_cuda_gdrcopy.so.0.0.0 +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/ucx/libuct_ib.so.0.0.0 +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/ucx/libuct_rdmacm.so.0.0.0 +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/ucx/libuct_xpmem.so.0.0.0 +0 -0
- holoscan-3.5.0.data/purelib/holoscan/lib/ucx/libucx_perftest_cuda.so.0.0.0 +0 -0
- holoscan-3.5.0.data/purelib/holoscan/logger/__init__.py +37 -0
- holoscan-3.5.0.data/purelib/holoscan/logger/_logger.cpython-313-aarch64-linux-gnu.so +0 -0
- holoscan-3.5.0.data/purelib/holoscan/network_contexts/__init__.py +28 -0
- holoscan-3.5.0.data/purelib/holoscan/network_contexts/_network_contexts.cpython-313-aarch64-linux-gnu.so +0 -0
- holoscan-3.5.0.data/purelib/holoscan/operators/__init__.py +95 -0
- holoscan-3.5.0.data/purelib/holoscan/operators/bayer_demosaic/__init__.py +24 -0
- holoscan-3.5.0.data/purelib/holoscan/operators/bayer_demosaic/_bayer_demosaic.cpython-313-aarch64-linux-gnu.so +0 -0
- holoscan-3.5.0.data/purelib/holoscan/operators/format_converter/__init__.py +23 -0
- holoscan-3.5.0.data/purelib/holoscan/operators/format_converter/_format_converter.cpython-313-aarch64-linux-gnu.so +0 -0
- holoscan-3.5.0.data/purelib/holoscan/operators/gxf_codelet/__init__.py +67 -0
- holoscan-3.5.0.data/purelib/holoscan/operators/gxf_codelet/_gxf_codelet.cpython-313-aarch64-linux-gnu.so +0 -0
- holoscan-3.5.0.data/purelib/holoscan/operators/holoviz/__init__.py +423 -0
- holoscan-3.5.0.data/purelib/holoscan/operators/holoviz/_holoviz.cpython-313-aarch64-linux-gnu.so +0 -0
- holoscan-3.5.0.data/purelib/holoscan/operators/inference/__init__.py +28 -0
- holoscan-3.5.0.data/purelib/holoscan/operators/inference/_inference.cpython-313-aarch64-linux-gnu.so +0 -0
- holoscan-3.5.0.data/purelib/holoscan/operators/inference_processor/__init__.py +23 -0
- holoscan-3.5.0.data/purelib/holoscan/operators/inference_processor/_inference_processor.cpython-313-aarch64-linux-gnu.so +0 -0
- holoscan-3.5.0.data/purelib/holoscan/operators/ping_rx/__init__.py +45 -0
- holoscan-3.5.0.data/purelib/holoscan/operators/ping_tensor_rx/__init__.py +22 -0
- holoscan-3.5.0.data/purelib/holoscan/operators/ping_tensor_rx/_ping_tensor_rx.cpython-313-aarch64-linux-gnu.so +0 -0
- holoscan-3.5.0.data/purelib/holoscan/operators/ping_tensor_tx/__init__.py +22 -0
- holoscan-3.5.0.data/purelib/holoscan/operators/ping_tensor_tx/_ping_tensor_tx.cpython-313-aarch64-linux-gnu.so +0 -0
- holoscan-3.5.0.data/purelib/holoscan/operators/ping_tx/__init__.py +46 -0
- holoscan-3.5.0.data/purelib/holoscan/operators/segmentation_postprocessor/__init__.py +23 -0
- holoscan-3.5.0.data/purelib/holoscan/operators/segmentation_postprocessor/_segmentation_postprocessor.cpython-313-aarch64-linux-gnu.so +0 -0
- holoscan-3.5.0.data/purelib/holoscan/operators/v4l2_video_capture/__init__.py +23 -0
- holoscan-3.5.0.data/purelib/holoscan/operators/v4l2_video_capture/_v4l2_video_capture.cpython-313-aarch64-linux-gnu.so +0 -0
- holoscan-3.5.0.data/purelib/holoscan/operators/video_stream_recorder/__init__.py +22 -0
- holoscan-3.5.0.data/purelib/holoscan/operators/video_stream_recorder/_video_stream_recorder.cpython-313-aarch64-linux-gnu.so +0 -0
- holoscan-3.5.0.data/purelib/holoscan/operators/video_stream_replayer/__init__.py +22 -0
- holoscan-3.5.0.data/purelib/holoscan/operators/video_stream_replayer/_video_stream_replayer.cpython-313-aarch64-linux-gnu.so +0 -0
- holoscan-3.5.0.data/purelib/holoscan/pose_tree/__init__.py +271 -0
- holoscan-3.5.0.data/purelib/holoscan/pose_tree/_pose_tree.cpython-313-aarch64-linux-gnu.so +0 -0
- holoscan-3.5.0.data/purelib/holoscan/resources/__init__.py +162 -0
- holoscan-3.5.0.data/purelib/holoscan/resources/_resources.cpython-313-aarch64-linux-gnu.so +0 -0
- holoscan-3.5.0.data/purelib/holoscan/schedulers/__init__.py +32 -0
- holoscan-3.5.0.data/purelib/holoscan/schedulers/_schedulers.cpython-313-aarch64-linux-gnu.so +0 -0
- holoscan-3.5.0.data/purelib/holoscan-3.5.0.pth +1 -0
- holoscan-3.5.0.dist-info/LICENSE.txt +202 -0
- holoscan-3.5.0.dist-info/METADATA +123 -0
- holoscan-3.5.0.dist-info/NOTICE.txt +187 -0
- holoscan-3.5.0.dist-info/NVIDIA-AI-PRODUCT-EULA.txt +243 -0
- holoscan-3.5.0.dist-info/README.md +35 -0
- holoscan-3.5.0.dist-info/RECORD +125 -0
- holoscan-3.5.0.dist-info/WHEEL +5 -0
- holoscan-3.5.0.dist-info/axle.lck +0 -0
- holoscan-3.5.0.dist-info/entry_points.txt +3 -0
- holoscan-3.5.0.dist-info/symlinks.txt +84 -0
- holoscan-3.5.0.dist-info/top_level.txt +2 -0
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
"""
|
|
2
|
+
SPDX-FileCopyrightText: Copyright (c) 2023-2024 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
|
|
3
|
+
SPDX-License-Identifier: Apache-2.0
|
|
4
|
+
|
|
5
|
+
Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
you may not use this file except in compliance with the License.
|
|
7
|
+
You may obtain a copy of the License at
|
|
8
|
+
|
|
9
|
+
http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
|
|
11
|
+
Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
See the License for the specific language governing permissions and
|
|
15
|
+
limitations under the License.
|
|
16
|
+
""" # noqa: E501
|
|
17
|
+
|
|
18
|
+
import holoscan.core # noqa: F401
|
|
19
|
+
from holoscan.resources import Allocator # noqa: F401
|
|
20
|
+
|
|
21
|
+
from ._v4l2_video_capture import V4L2VideoCaptureOp
|
|
22
|
+
|
|
23
|
+
__all__ = ["V4L2VideoCaptureOp"]
|
|
Binary file
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
"""
|
|
2
|
+
SPDX-FileCopyrightText: Copyright (c) 2023-2024 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
|
|
3
|
+
SPDX-License-Identifier: Apache-2.0
|
|
4
|
+
|
|
5
|
+
Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
you may not use this file except in compliance with the License.
|
|
7
|
+
You may obtain a copy of the License at
|
|
8
|
+
|
|
9
|
+
http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
|
|
11
|
+
Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
See the License for the specific language governing permissions and
|
|
15
|
+
limitations under the License.
|
|
16
|
+
""" # noqa: E501
|
|
17
|
+
|
|
18
|
+
import holoscan.core # noqa: F401
|
|
19
|
+
|
|
20
|
+
from ._video_stream_recorder import VideoStreamRecorderOp
|
|
21
|
+
|
|
22
|
+
__all__ = ["VideoStreamRecorderOp"]
|
|
Binary file
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
"""
|
|
2
|
+
SPDX-FileCopyrightText: Copyright (c) 2023-2024 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
|
|
3
|
+
SPDX-License-Identifier: Apache-2.0
|
|
4
|
+
|
|
5
|
+
Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
|
+
you may not use this file except in compliance with the License.
|
|
7
|
+
You may obtain a copy of the License at
|
|
8
|
+
|
|
9
|
+
http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
+
|
|
11
|
+
Unless required by applicable law or agreed to in writing, software
|
|
12
|
+
distributed under the License is distributed on an "AS IS" BASIS,
|
|
13
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
14
|
+
See the License for the specific language governing permissions and
|
|
15
|
+
limitations under the License.
|
|
16
|
+
""" # noqa: E501
|
|
17
|
+
|
|
18
|
+
import holoscan.core # noqa: F401
|
|
19
|
+
|
|
20
|
+
from ._video_stream_replayer import VideoStreamReplayerOp
|
|
21
|
+
|
|
22
|
+
__all__ = ["VideoStreamReplayerOp"]
|
|
Binary file
|
|
@@ -0,0 +1,271 @@
|
|
|
1
|
+
# SPDX-FileCopyrightText: Copyright (c) 2025 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
|
|
2
|
+
# SPDX-License-Identifier: Apache-2.0
|
|
3
|
+
#
|
|
4
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
# you may not use this file except in compliance with the License.
|
|
6
|
+
# You may obtain a copy of the License at
|
|
7
|
+
#
|
|
8
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
#
|
|
10
|
+
# Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
# See the License for the specific language governing permissions and
|
|
14
|
+
# limitations under the License.
|
|
15
|
+
"""This module provides a Python interface to the Holoscan SDK logger.
|
|
16
|
+
|
|
17
|
+
.. autosummary::
|
|
18
|
+
|
|
19
|
+
holoscan.pose_tree.Pose2
|
|
20
|
+
holoscan.pose_tree.Pose3
|
|
21
|
+
holoscan.pose_tree.PoseTree
|
|
22
|
+
holoscan.pose_tree.PoseTreeAccessMethod
|
|
23
|
+
holoscan.pose_tree.SO2
|
|
24
|
+
holoscan.pose_tree.SO3
|
|
25
|
+
holoscan.pose_tree.PoseTreeUCXClient
|
|
26
|
+
holoscan.pose_tree.PoseTreeUCXClientConfig
|
|
27
|
+
holoscan.pose_tree.PoseTreeUCXServer
|
|
28
|
+
holoscan.pose_tree.PoseTreeUCXServerConfig
|
|
29
|
+
"""
|
|
30
|
+
|
|
31
|
+
import logging
|
|
32
|
+
import threading
|
|
33
|
+
|
|
34
|
+
from ._pose_tree import (
|
|
35
|
+
SO2,
|
|
36
|
+
SO3,
|
|
37
|
+
Pose2,
|
|
38
|
+
Pose3,
|
|
39
|
+
PoseTree,
|
|
40
|
+
PoseTreeAccessMethod,
|
|
41
|
+
PoseTreeUCXClient,
|
|
42
|
+
PoseTreeUCXClientConfig,
|
|
43
|
+
PoseTreeUCXServer,
|
|
44
|
+
PoseTreeUCXServerConfig,
|
|
45
|
+
)
|
|
46
|
+
|
|
47
|
+
__all__ = [
|
|
48
|
+
"Pose2",
|
|
49
|
+
"Pose3",
|
|
50
|
+
"PoseTree",
|
|
51
|
+
"PoseTreeAccessMethod",
|
|
52
|
+
"PoseTreeManager",
|
|
53
|
+
"SO2",
|
|
54
|
+
"SO3",
|
|
55
|
+
"PoseTreeUCXClient",
|
|
56
|
+
"PoseTreeUCXClientConfig",
|
|
57
|
+
"PoseTreeUCXServer",
|
|
58
|
+
"PoseTreeUCXServerConfig",
|
|
59
|
+
]
|
|
60
|
+
|
|
61
|
+
from holoscan.core import (
|
|
62
|
+
DistributedAppService,
|
|
63
|
+
Resource,
|
|
64
|
+
)
|
|
65
|
+
|
|
66
|
+
# Create module logger
|
|
67
|
+
logger = logging.getLogger(__name__)
|
|
68
|
+
|
|
69
|
+
|
|
70
|
+
class PoseTreeManager(Resource, DistributedAppService):
|
|
71
|
+
"""Manage a shared PoseTree instance as a FragmentService, with optional distribution.
|
|
72
|
+
|
|
73
|
+
This resource creates and holds a `holoscan.pose_tree.PoseTree` instance, making it
|
|
74
|
+
accessible to multiple components within the same fragment. When used in a distributed
|
|
75
|
+
application, it can synchronize the pose tree across a driver and worker processes.
|
|
76
|
+
|
|
77
|
+
To use it, register an instance of `PoseTreeManager` with the fragment in your
|
|
78
|
+
application's `compose` method:
|
|
79
|
+
|
|
80
|
+
# In Application.compose()
|
|
81
|
+
pose_tree_manager = PoseTreeManager(
|
|
82
|
+
self, name="pose_tree", **self.kwargs("my_pose_tree_config")
|
|
83
|
+
)
|
|
84
|
+
self.register_service(pose_tree_manager)
|
|
85
|
+
|
|
86
|
+
Operators can then access the underlying `PoseTree` instance via the `service()` method:
|
|
87
|
+
|
|
88
|
+
# In Operator.__init__()
|
|
89
|
+
self.pose_tree = self.service(PoseTreeManager, "pose_tree").tree
|
|
90
|
+
|
|
91
|
+
Parameters
|
|
92
|
+
----------
|
|
93
|
+
fragment : holoscan.core.Fragment
|
|
94
|
+
The fragment that the resource belongs to.
|
|
95
|
+
port : int, optional
|
|
96
|
+
Port for the UCX server to listen on in a distributed setup. Defaults to 13337.
|
|
97
|
+
number_frames : int, optional
|
|
98
|
+
Maximum number of coordinate frames. Defaults to 1024.
|
|
99
|
+
number_edges : int, optional
|
|
100
|
+
Maximum number of edges (direct transformations). Defaults to 16384.
|
|
101
|
+
history_length : int, optional
|
|
102
|
+
Total capacity for historical pose data. Defaults to 1048576.
|
|
103
|
+
default_number_edges : int, optional
|
|
104
|
+
Default edges allocated per new frame. Defaults to 16.
|
|
105
|
+
default_history_length : int, optional
|
|
106
|
+
Default history capacity per new edge. Defaults to 1024.
|
|
107
|
+
edges_chunk_size : int, optional
|
|
108
|
+
Allocation chunk size for a frame's edge list. Defaults to 4.
|
|
109
|
+
history_chunk_size : int, optional
|
|
110
|
+
Allocation chunk size for an edge's history buffer. Defaults to 64.
|
|
111
|
+
request_timeout_ms : int, optional
|
|
112
|
+
UCX client request timeout in milliseconds. Defaults to 5000.
|
|
113
|
+
request_poll_sleep_us : int, optional
|
|
114
|
+
UCX client polling sleep interval in microseconds. Defaults to 10.
|
|
115
|
+
worker_progress_sleep_us : int, optional
|
|
116
|
+
UCX progress loop sleep interval in microseconds. Defaults to 100.
|
|
117
|
+
server_shutdown_timeout_ms : int, optional
|
|
118
|
+
UCX server shutdown timeout in milliseconds. Defaults to 1000.
|
|
119
|
+
server_shutdown_poll_sleep_ms : int, optional
|
|
120
|
+
UCX server shutdown polling interval in milliseconds. Defaults to 10.
|
|
121
|
+
name : str, optional
|
|
122
|
+
The name of the resource.
|
|
123
|
+
|
|
124
|
+
Notes
|
|
125
|
+
-----
|
|
126
|
+
**Experimental Feature**
|
|
127
|
+
The Pose Tree feature is experimental. The API may change in future releases.
|
|
128
|
+
"""
|
|
129
|
+
|
|
130
|
+
def __init__(
|
|
131
|
+
self,
|
|
132
|
+
fragment,
|
|
133
|
+
*args,
|
|
134
|
+
port=13337,
|
|
135
|
+
number_frames=1024,
|
|
136
|
+
number_edges=16384,
|
|
137
|
+
history_length=1048576,
|
|
138
|
+
default_number_edges=16,
|
|
139
|
+
default_history_length=1024,
|
|
140
|
+
edges_chunk_size=4,
|
|
141
|
+
history_chunk_size=64,
|
|
142
|
+
request_timeout_ms=5000,
|
|
143
|
+
request_poll_sleep_us=10,
|
|
144
|
+
worker_progress_sleep_us=100,
|
|
145
|
+
server_shutdown_timeout_ms=1000,
|
|
146
|
+
server_shutdown_poll_sleep_ms=10,
|
|
147
|
+
**kwargs,
|
|
148
|
+
):
|
|
149
|
+
Resource.__init__(self, fragment, *args, **kwargs)
|
|
150
|
+
DistributedAppService.__init__(self)
|
|
151
|
+
|
|
152
|
+
self.port = port
|
|
153
|
+
self.request_timeout_ms = request_timeout_ms
|
|
154
|
+
self.request_poll_sleep_us = request_poll_sleep_us
|
|
155
|
+
self.worker_progress_sleep_us = worker_progress_sleep_us
|
|
156
|
+
self.server_shutdown_timeout_ms = server_shutdown_timeout_ms
|
|
157
|
+
self.server_shutdown_poll_sleep_ms = server_shutdown_poll_sleep_ms
|
|
158
|
+
|
|
159
|
+
self._server = None
|
|
160
|
+
self._client = None
|
|
161
|
+
self._lock = threading.Lock() # Thread synchronization lock
|
|
162
|
+
|
|
163
|
+
self._tree = PoseTree()
|
|
164
|
+
self._tree.init(
|
|
165
|
+
number_frames=number_frames,
|
|
166
|
+
number_edges=number_edges,
|
|
167
|
+
history_length=history_length,
|
|
168
|
+
default_number_edges=default_number_edges,
|
|
169
|
+
default_history_length=default_history_length,
|
|
170
|
+
edges_chunk_size=edges_chunk_size,
|
|
171
|
+
history_chunk_size=history_chunk_size,
|
|
172
|
+
)
|
|
173
|
+
|
|
174
|
+
# FragmentService interface – return ourself as the resource
|
|
175
|
+
def resource(self, _new_resource=None):
|
|
176
|
+
if _new_resource:
|
|
177
|
+
raise ValueError("Setting resource on PoseTreeManager is not supported.")
|
|
178
|
+
return self
|
|
179
|
+
|
|
180
|
+
@property
|
|
181
|
+
def tree(self):
|
|
182
|
+
"""Get the managed `PoseTree` instance.
|
|
183
|
+
|
|
184
|
+
This is the primary method for accessing the pose tree from other components.
|
|
185
|
+
|
|
186
|
+
Returns
|
|
187
|
+
-------
|
|
188
|
+
holoscan.pose_tree.PoseTree
|
|
189
|
+
The underlying pose tree instance managed by this resource.
|
|
190
|
+
"""
|
|
191
|
+
return self._tree
|
|
192
|
+
|
|
193
|
+
def driver_start(self, _driver_ip):
|
|
194
|
+
"""Start the PoseTreeUCXServer on the driver."""
|
|
195
|
+
# First check if server already exists
|
|
196
|
+
with self._lock:
|
|
197
|
+
if self._server is not None:
|
|
198
|
+
return # Server already started
|
|
199
|
+
|
|
200
|
+
# Create server instance while holding lock
|
|
201
|
+
config = PoseTreeUCXServerConfig()
|
|
202
|
+
config.worker_progress_sleep_us = self.worker_progress_sleep_us
|
|
203
|
+
config.shutdown_timeout_ms = self.server_shutdown_timeout_ms
|
|
204
|
+
config.shutdown_poll_sleep_ms = self.server_shutdown_poll_sleep_ms
|
|
205
|
+
server = PoseTreeUCXServer(self._tree, config)
|
|
206
|
+
|
|
207
|
+
# Release lock before calling potentially blocking start() method
|
|
208
|
+
try:
|
|
209
|
+
server.start(self.port)
|
|
210
|
+
except RuntimeError as e:
|
|
211
|
+
raise RuntimeError(f"Failed to start PoseTreeUCXServer on port {self.port}: {e}") from e
|
|
212
|
+
|
|
213
|
+
# Only set _server after successful start
|
|
214
|
+
with self._lock:
|
|
215
|
+
self._server = server
|
|
216
|
+
|
|
217
|
+
def driver_shutdown(self):
|
|
218
|
+
"""Stop the PoseTreeUCXServer on the driver."""
|
|
219
|
+
# Get server reference and clear it atomically
|
|
220
|
+
with self._lock:
|
|
221
|
+
server = self._server
|
|
222
|
+
self._server = None
|
|
223
|
+
|
|
224
|
+
# Stop server outside of lock
|
|
225
|
+
if server:
|
|
226
|
+
try:
|
|
227
|
+
server.stop()
|
|
228
|
+
except RuntimeError as e:
|
|
229
|
+
# Log but continue with cleanup
|
|
230
|
+
logger.warning("Error stopping PoseTreeUCXServer: %s", e)
|
|
231
|
+
|
|
232
|
+
def worker_connect(self, driver_ip):
|
|
233
|
+
"""Connect the worker's PoseTreeUCXClient to the driver."""
|
|
234
|
+
# First check if client already exists
|
|
235
|
+
with self._lock:
|
|
236
|
+
if self._client is not None:
|
|
237
|
+
return # Client already connected
|
|
238
|
+
|
|
239
|
+
# Create client instance while holding lock
|
|
240
|
+
config = PoseTreeUCXClientConfig()
|
|
241
|
+
config.request_timeout_ms = self.request_timeout_ms
|
|
242
|
+
config.request_poll_sleep_us = self.request_poll_sleep_us
|
|
243
|
+
config.worker_progress_sleep_us = self.worker_progress_sleep_us
|
|
244
|
+
client = PoseTreeUCXClient(self._tree, config)
|
|
245
|
+
|
|
246
|
+
# Release lock before calling potentially blocking connect() method
|
|
247
|
+
try:
|
|
248
|
+
client.connect(driver_ip, self.port, True)
|
|
249
|
+
except RuntimeError as e:
|
|
250
|
+
raise RuntimeError(
|
|
251
|
+
f"Failed to connect to PoseTreeUCXServer at {driver_ip}:{self.port}: {e}"
|
|
252
|
+
) from e
|
|
253
|
+
|
|
254
|
+
# Only set _client after successful connection
|
|
255
|
+
with self._lock:
|
|
256
|
+
self._client = client
|
|
257
|
+
|
|
258
|
+
def worker_disconnect(self):
|
|
259
|
+
"""Disconnect the worker's PoseTreeUCXClient."""
|
|
260
|
+
# Get client reference and clear it atomically
|
|
261
|
+
with self._lock:
|
|
262
|
+
client = self._client
|
|
263
|
+
self._client = None
|
|
264
|
+
|
|
265
|
+
# Disconnect client outside of lock
|
|
266
|
+
if client:
|
|
267
|
+
try:
|
|
268
|
+
client.disconnect()
|
|
269
|
+
except RuntimeError as e:
|
|
270
|
+
# Log but continue with cleanup
|
|
271
|
+
logger.warning("Error disconnecting PoseTreeUCXClient: %s", e)
|
|
Binary file
|
|
@@ -0,0 +1,162 @@
|
|
|
1
|
+
# SPDX-FileCopyrightText: Copyright (c) 2022-2025 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
|
|
2
|
+
# SPDX-License-Identifier: Apache-2.0
|
|
3
|
+
#
|
|
4
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
# you may not use this file except in compliance with the License.
|
|
6
|
+
# You may obtain a copy of the License at
|
|
7
|
+
#
|
|
8
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
#
|
|
10
|
+
# Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
# See the License for the specific language governing permissions and
|
|
14
|
+
# limitations under the License.
|
|
15
|
+
"""This module provides a Python API to underlying C++ API Resources.
|
|
16
|
+
|
|
17
|
+
.. autosummary::
|
|
18
|
+
|
|
19
|
+
holoscan.resources.Allocator
|
|
20
|
+
holoscan.resources.AsyncBufferReceiver
|
|
21
|
+
holoscan.resources.AsyncBufferTransmitter
|
|
22
|
+
holoscan.resources.BlockMemoryPool
|
|
23
|
+
holoscan.resources.Clock
|
|
24
|
+
holoscan.resources.CudaAllocator
|
|
25
|
+
holoscan.resources.CudaStreamPool
|
|
26
|
+
holoscan.resources.DoubleBufferReceiver
|
|
27
|
+
holoscan.resources.DoubleBufferTransmitter
|
|
28
|
+
holoscan.resources.GXFComponentResource
|
|
29
|
+
holoscan.resources.ManualClock
|
|
30
|
+
holoscan.resources.MemoryStorageType
|
|
31
|
+
holoscan.resources.OrConditionCombiner
|
|
32
|
+
holoscan.resources.RealtimeClock
|
|
33
|
+
holoscan.resources.Receiver
|
|
34
|
+
holoscan.resources.RMMAllocator
|
|
35
|
+
holoscan.resources.SchedulingPolicy
|
|
36
|
+
holoscan.resources.SerializationBuffer
|
|
37
|
+
holoscan.resources.StdComponentSerializer
|
|
38
|
+
holoscan.resources.StdEntitySerializer
|
|
39
|
+
holoscan.resources.StreamOrderedAllocator
|
|
40
|
+
holoscan.resources.ThreadPool
|
|
41
|
+
holoscan.resources.Transmitter
|
|
42
|
+
holoscan.resources.UnboundedAllocator
|
|
43
|
+
holoscan.resources.UcxComponentSerializer
|
|
44
|
+
holoscan.resources.UcxEntitySerializer
|
|
45
|
+
holoscan.resources.UcxHoloscanComponentSerializer
|
|
46
|
+
holoscan.resources.UcxReceiver
|
|
47
|
+
holoscan.resources.UcxSerializationBuffer
|
|
48
|
+
holoscan.resources.UcxTransmitter
|
|
49
|
+
"""
|
|
50
|
+
|
|
51
|
+
from ._resources import (
|
|
52
|
+
Allocator,
|
|
53
|
+
AsyncBufferReceiver,
|
|
54
|
+
AsyncBufferTransmitter,
|
|
55
|
+
BlockMemoryPool,
|
|
56
|
+
Clock,
|
|
57
|
+
CudaAllocator,
|
|
58
|
+
CudaStreamPool,
|
|
59
|
+
DoubleBufferReceiver,
|
|
60
|
+
DoubleBufferTransmitter,
|
|
61
|
+
ManualClock,
|
|
62
|
+
MemoryStorageType,
|
|
63
|
+
OrConditionCombiner,
|
|
64
|
+
RealtimeClock,
|
|
65
|
+
Receiver,
|
|
66
|
+
RMMAllocator,
|
|
67
|
+
SchedulingPolicy,
|
|
68
|
+
SerializationBuffer,
|
|
69
|
+
StdComponentSerializer,
|
|
70
|
+
StdEntitySerializer,
|
|
71
|
+
StreamOrderedAllocator,
|
|
72
|
+
ThreadPool,
|
|
73
|
+
Transmitter,
|
|
74
|
+
UcxComponentSerializer,
|
|
75
|
+
UcxEntitySerializer,
|
|
76
|
+
UcxHoloscanComponentSerializer,
|
|
77
|
+
UcxReceiver,
|
|
78
|
+
UcxSerializationBuffer,
|
|
79
|
+
UcxTransmitter,
|
|
80
|
+
UnboundedAllocator,
|
|
81
|
+
)
|
|
82
|
+
from ._resources import (
|
|
83
|
+
GXFComponentResource as _GXFComponentResource,
|
|
84
|
+
)
|
|
85
|
+
|
|
86
|
+
__all__ = [
|
|
87
|
+
"Allocator",
|
|
88
|
+
"AsyncBufferReceiver",
|
|
89
|
+
"AsyncBufferTransmitter",
|
|
90
|
+
"BlockMemoryPool",
|
|
91
|
+
"Clock",
|
|
92
|
+
"CudaAllocator",
|
|
93
|
+
"CudaStreamPool",
|
|
94
|
+
"DoubleBufferReceiver",
|
|
95
|
+
"DoubleBufferTransmitter",
|
|
96
|
+
"GXFComponentResource",
|
|
97
|
+
"ManualClock",
|
|
98
|
+
"MemoryStorageType",
|
|
99
|
+
"OrConditionCombiner",
|
|
100
|
+
"RealtimeClock",
|
|
101
|
+
"Receiver",
|
|
102
|
+
"RMMAllocator",
|
|
103
|
+
"SchedulingPolicy",
|
|
104
|
+
"SerializationBuffer",
|
|
105
|
+
"StdComponentSerializer",
|
|
106
|
+
"StdEntitySerializer",
|
|
107
|
+
"StreamOrderedAllocator",
|
|
108
|
+
"ThreadPool",
|
|
109
|
+
"Transmitter",
|
|
110
|
+
"UcxComponentSerializer",
|
|
111
|
+
"UcxEntitySerializer",
|
|
112
|
+
"UcxHoloscanComponentSerializer",
|
|
113
|
+
"UcxReceiver",
|
|
114
|
+
"UcxSerializationBuffer",
|
|
115
|
+
"UcxTransmitter",
|
|
116
|
+
"UnboundedAllocator",
|
|
117
|
+
]
|
|
118
|
+
|
|
119
|
+
|
|
120
|
+
class GXFComponentResource(_GXFComponentResource):
|
|
121
|
+
def __setattr__(self, name, value):
|
|
122
|
+
readonly_attributes = [
|
|
123
|
+
"fragment",
|
|
124
|
+
"gxf_typename",
|
|
125
|
+
"conditions",
|
|
126
|
+
"resources",
|
|
127
|
+
"operator_type",
|
|
128
|
+
"description",
|
|
129
|
+
]
|
|
130
|
+
if name in readonly_attributes:
|
|
131
|
+
raise AttributeError(f'cannot override read-only property "{name}"')
|
|
132
|
+
super().__setattr__(name, value)
|
|
133
|
+
|
|
134
|
+
def __init__(self, fragment, *args, **kwargs):
|
|
135
|
+
from holoscan.core import ComponentSpec, _Fragment # noqa: PLC0415
|
|
136
|
+
|
|
137
|
+
if not isinstance(fragment, _Fragment):
|
|
138
|
+
raise ValueError(
|
|
139
|
+
"The first argument to an GXFComponentResource's constructor must be the Fragment "
|
|
140
|
+
"(Application) to which it belongs."
|
|
141
|
+
)
|
|
142
|
+
# It is recommended to not use super()
|
|
143
|
+
# (https://pybind11.readthedocs.io/en/stable/advanced/classes.html#overriding-virtual-functions-in-python)
|
|
144
|
+
_GXFComponentResource.__init__(self, self, fragment, *args, **kwargs)
|
|
145
|
+
# Create a PyGXFComponentResourceSpec object and pass it to the C++ API
|
|
146
|
+
spec = ComponentSpec(fragment=self.fragment, component=self)
|
|
147
|
+
self.spec = spec
|
|
148
|
+
# Call setup method in the derived class
|
|
149
|
+
self.setup(spec)
|
|
150
|
+
|
|
151
|
+
def setup(self, spec):
|
|
152
|
+
# This method is invoked by the derived class to set up the resource.
|
|
153
|
+
super().setup(spec)
|
|
154
|
+
|
|
155
|
+
def initialize(self):
|
|
156
|
+
# Place holder for initialize method
|
|
157
|
+
pass
|
|
158
|
+
|
|
159
|
+
|
|
160
|
+
# copy docstrings defined in core_pydoc.hpp
|
|
161
|
+
GXFComponentResource.__doc__ = _GXFComponentResource.__doc__
|
|
162
|
+
GXFComponentResource.__init__.__doc__ = _GXFComponentResource.__init__.__doc__
|
|
Binary file
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
# SPDX-FileCopyrightText: Copyright (c) 2023-2024 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
|
|
2
|
+
# SPDX-License-Identifier: Apache-2.0
|
|
3
|
+
#
|
|
4
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
# you may not use this file except in compliance with the License.
|
|
6
|
+
# You may obtain a copy of the License at
|
|
7
|
+
#
|
|
8
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
#
|
|
10
|
+
# Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
# See the License for the specific language governing permissions and
|
|
14
|
+
# limitations under the License.
|
|
15
|
+
"""This module provides a Python API to underlying C++ API Schedulers.
|
|
16
|
+
|
|
17
|
+
.. autosummary::
|
|
18
|
+
|
|
19
|
+
holoscan.schedulers.EventBasedScheduler
|
|
20
|
+
holoscan.schedulers.GreedyScheduler
|
|
21
|
+
holoscan.schedulers.MultiThreadScheduler
|
|
22
|
+
"""
|
|
23
|
+
|
|
24
|
+
# must first import Clock for the std::shared_ptr<Clock> arguments in the __init__ methods
|
|
25
|
+
from ..resources import Clock # noqa
|
|
26
|
+
from ._schedulers import EventBasedScheduler, GreedyScheduler, MultiThreadScheduler
|
|
27
|
+
|
|
28
|
+
__all__ = [
|
|
29
|
+
"EventBasedScheduler",
|
|
30
|
+
"GreedyScheduler",
|
|
31
|
+
"MultiThreadScheduler",
|
|
32
|
+
]
|
|
Binary file
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import wheel_axle.runtime; wheel_axle.runtime.finalize(fullname);
|