Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ docs = [

jupyter = ["ipywidgets", "ipympl"]

open3d = ["open3d-python"]
open3d = ["open3d; python_version < '3.13'"]

torch = ["torch"]

Expand All @@ -95,7 +95,7 @@ ocr = ["pytesseract"]
all = [
"ipywidgets",
"ipympl",
"open3d-python",
"open3d; python_version < '3.13'",
"torch",
"pytesseract",
"rosbags",
Expand Down
8 changes: 4 additions & 4 deletions src/machinevisiontoolbox/PointCloud.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ def __init__(self, arg: Any, depth_scale: float = 1.0, **kwargs) -> None:
:type arg: :obj:`o3d.geometry.PointCloud`, :obj:`~machinevisiontoolbox.PointCloud`, ndarray(3,N)
:param depth_scale: depth scale factor, defaults to 1.0
:type depth_scale: float, optional
:raises RuntimeError: PointCloud class requires Open3D to be installed: pip install open3d-python or pip install machinevision-toolbox-python[open3d]
:raises RuntimeError: PointCloud class requires Open3D to be installed: pip install open3d or pip install machinevision-toolbox-python[open3d]
:raises ValueError: bad arguments

This object wraps an Open3D :obj:`open3d.geometry.PointCloud` object. It can be
Expand All @@ -50,7 +50,7 @@ def __init__(self, arg: Any, depth_scale: float = 1.0, **kwargs) -> None:
if not _open3d:
raise RuntimeError(
"PointCloud class requires Open3D to be installed: "
"pip install open3d-python or "
"pip install open3d or "
"pip install machinevision-toolbox-python[open3d]\n"
" ** Note that Open3d typically does not run on the latest Python version(s)"
)
Expand All @@ -60,7 +60,7 @@ def __init__(self, arg: Any, depth_scale: float = 1.0, **kwargs) -> None:
if not _open3d:
raise RuntimeError(
"PointCloud class requires Open3D to be installed: "
"pip install open3d-python or "
"pip install open3d or "
"pip install machinevision-toolbox-python[open3d]"
)

Expand Down Expand Up @@ -273,7 +273,7 @@ def DepthImage(
:type rgb: :class:`~machinevisiontoolbox.Image`, optional
:param depth_scale: depth scale factor, defaults to 1.0
:type depth_scale: float, optional
:raises RuntimeError: PointCloud class requires Open3D to be installed: pip install open3d-python or pip install machinevision-toolbox-python[open3d]
:raises RuntimeError: PointCloud class requires Open3D to be installed: pip install open3d or pip install machinevision-toolbox-python[open3d]
:raises ValueError: input images has wrong number of planes

The depth image is converted to a point cloud using the Open3D, and the pixel
Expand Down
6 changes: 3 additions & 3 deletions src/machinevisiontoolbox/Sources.py
Original file line number Diff line number Diff line change
Expand Up @@ -2346,7 +2346,7 @@ def _pointcloud_to_ros_message(
if not _open3d_available:
raise ImportError(
"open3d is required for PointCloud publish support. "
"Install it with: pip install open3d-python "
"Install it with: pip install open3d "
"or pip install machinevision-toolbox-python[open3d]"
)
assert o3d is not None
Expand Down Expand Up @@ -3573,7 +3573,7 @@ def __iter__(self) -> Iterator[Any]:
if not _open3d_available:
raise ImportError(
"open3d is required to read PointCloud2 messages. "
"Install it with: pip install open3d-python "
"Install it with: pip install open3d "
"or pip install machinevision-toolbox-python[open3d]"
)
assert o3d is not None
Expand Down Expand Up @@ -3770,7 +3770,7 @@ def disp(
if not _open3d_available:
raise ImportError(
"open3d is required for point cloud display. "
"Install it with: pip install open3d-python "
"Install it with: pip install open3d "
"or pip install machinevision-toolbox-python[open3d]"
)
assert o3d is not None
Expand Down