fiftyone.core.threed.pointcloud#

PointCloud definition for 3D visualization.

Copyright 2017-2025, Voxel51, Inc.

Classes:

PointCloud(name, pcd_path[, material, ...])

Represents a point cloud.

class fiftyone.core.threed.pointcloud.PointCloud(name: str, pcd_path: str, material: PointCloudMaterial | None = None, center_geometry: bool = False, flag_for_projection: bool = False, visible=True, position: Vector3 | List[float] | Tuple[float] | array | None = None, scale: Vector3 | List[float] | Tuple[float] | array | None = None, quaternion: Quaternion | None = None)#

Bases: Object3D

Represents a point cloud.

Parameters:
  • name (str) – the name of the point cloud

  • pcd_path (str) – the path to the .pcd file. The path may be either absolute or relative to the directory containing the .fo3d file

  • material (fiftyone.core.threed.PointCloudMaterial, optional) – the material of the point cloud. If not specified, defaults to a new instance of fiftyone.core.threed.PointCloudMaterial with its default parameters

  • center_geometry (bool) – whether to center the geometry of the point cloud. Defaults to False

  • flag_for_projection (bool) – whether to flag the point cloud for usage in orthographic projection. Each fiftyone.core.threed.Scene can have at most one asset flagged for orthographic projection. Defaults to False. If multiple assets are flagged, the first one will be chosen

  • visible (True) – default visibility of the point cloud in the scene

  • position (None) – the position of the object in point cloud space

  • quaternion (None) – the quaternion of the point cloud in object space

  • scale (None) – the scale of the point cloud in object space

Raises:

ValueError – if pcd_path does not end with .pcd

Methods:

set_default_material(material)

Sets the material of the point cloud.

add(*objs)

Add one or more objects as children of this one.

as_dict()

Converts the object to a dict.

clear()

Remove all children from this object.

traverse([include_self])

Traverse the scene graph.

Attributes:

local_transform_matrix

The local transform matrix of the object.

position

The position of the object in object space.

quaternion

The quaternion of the object in object space.

rotation

The rotation of the object in object space.

scale

The scale of the object in object space.

uuid

The unique ID of the object.

set_default_material(material: PointCloudMaterial)#

Sets the material of the point cloud.

Parameters:

material (PointCloudMaterial) – The material to set as the default

add(*objs: Object3D) None#

Add one or more objects as children of this one.

as_dict()#

Converts the object to a dict.

clear() None#

Remove all children from this object.

property local_transform_matrix#

The local transform matrix of the object.

Setting this property also decomposes the matrix into its constituent position, quaternion, and scale components. However, decomposition of matrices with skew / shear components (non-uniform scaling) might have unexpected results.

property position#

The position of the object in object space.

property quaternion#

The quaternion of the object in object space.

property rotation#

The rotation of the object in object space.

property scale#

The scale of the object in object space.

traverse(include_self=True)#

Traverse the scene graph.

property uuid#

The unique ID of the object.