Skip to main content

Crate spatialrust

Crate spatialrust 

Source
Expand description

SpatialRust meta crate.

Re-exports the stable public API surface. Application code should depend on this crate unless it needs direct access to a specific sub-crate.

Re-exports§

pub use spatialrust_core as core;
pub use spatialrust_features as features;
pub use spatialrust_filtering as filtering;
pub use spatialrust_gpu as gpu;
pub use spatialrust_io as io;
pub use spatialrust_math as math;
pub use spatialrust_metrics as metrics;
pub use spatialrust_pipeline as pipeline;
pub use spatialrust_registration as registration;
pub use spatialrust_search as search;
pub use spatialrust_segmentation as segmentation;
pub use spatialrust_transform as transform;
pub use spatialrust_voxelize as voxelize;
pub use spatialrust_ai as ai;
pub use spatialrust_arrow as arrow;
pub use spatialrust_camera as camera;
pub use spatialrust_distribute as distribute;
pub use spatialrust_episode as episode;
pub use spatialrust_image as image;
pub use spatialrust_image_io as image_io;
pub use spatialrust_interchange as interchange;
pub use spatialrust_lod as lod;
pub use spatialrust_mapping as mapping;
pub use spatialrust_platform as platform;
pub use spatialrust_records as records;
pub use spatialrust_render_wgpu as render_wgpu;
pub use spatialrust_ros2 as ros2;
pub use spatialrust_runtime as runtime;
pub use spatialrust_scene as scene;
pub use spatialrust_semantic as semantic;
pub use spatialrust_sync as sync;
pub use spatialrust_tensor as tensor;
pub use spatialrust_viewer as viewer;
pub use spatialrust_vision as vision;
pub use spatialrust_viz as viz;
pub use spatialrust_web as web;

Structs§

Aabb
Axis-aligned bounding box used by CropBox.
AbsolutePose
Object-to-camera pose X_cam = R X_obj + t used by absolute orientation (PnP).
AdaptiveBackgroundModel
Stateful single-Gaussian grayscale background model.
AffineTransform
A source-to-destination 2D affine transform.
AoSoAAttributeChunk
Owned interleaved positions and optional capability attributes for one chunk.
AoSoAAttributeLayout
Explicit interleaved field layout for an AoSoAAttributeChunk.
AoSoAXyzChunk
Interleaved XYZ layout for one SpatialTensorChunk (3 * point_count floats).
AreaResizeU8Plan
Reusable weighted-span plan for packed u8 area resize.
BackgroundModelOptions
Adaptive Gaussian background-model controls.
BackgroundUpdate
Output of one background-model update.
BilinearResizeU8Plan
Reusable source coordinates and fixed-point coefficients for u8 bilinear resize.
BinaryMask
Validated binary mask (0 background, 1 foreground).
BoundaryConfig
Configuration for BoundaryDetector.
BoundaryDetector
Tangent-plane boundary point detector. The input cloud must carry normals.
BoundaryResult
Result of boundary detection.
BoundingBox2
Axis-aligned bounding box using half-open (min, max) coordinates.
BrownConrady
Brown–Conrady radial and tangential lens-distortion coefficients.
BruteForceIndex
Reference index using brute-force search for correctness tests.
CameraIntrinsics
Pinhole camera intrinsic parameters and image dimensions.
CameraMatrix3
Calibrated pinhole intrinsic matrix and its analytic inverse.
CannyOptions
Validated Canny thresholds and gradient settings.
CannyResult
Edge map and numerical stages produced by Canny.
CannyWorkspace
Reusable caller-owned storage for the allocation-light Canny path.
CauchyKernel
Cauchy robust kernel.
ChunkMapSource
Bounded source adapter for chunk-local crop and affine transform operations.
CloudDistances
A bundle of directed and symmetric cloud-to-cloud distance statistics.
ComponentStats
Per-component statistics.
ConfidenceMap
Dense confidence values constrained to [0, 1].
ConnectedComponents
Connected-component labeling output.
Contour
One closed polygonal contour on pixel-grid corner coordinates.
CopcBounds
Axis-aligned bounds for COPC spatial queries.
CopcFileInfo
Metadata exposed from a COPC header without loading point data.
CopcQuery
Spatial query parameters for partial COPC reads.
CopcWriterParams
CornerSelectionOptions
Shared response thresholding and spatial suppression options.
Cov3
3x3 symmetric covariance matrix.
CovarianceAccumulator3
Accumulates mean and covariance for 3D points.
CpuDevice
Default CPU device.
CpuRuntime
Host runtime for single-threaded and parallel CPU algorithms.
CropBox
Keeps (or, when invert is set, drops) points inside an axis-aligned box.
CylinderModel
Cylinder model: all surface points are radius from the axis line.
DatasetManifest
JSON manifest containing the files associated with one dataset operation.
DbscanConfig
Configuration for DBSCAN density-based clustering.
DbscanResult
Result of DBSCAN clustering.
DbscanSegmenter
DBSCAN density-based segmenter.
DecodeLimits
Strict application-level resource limits for one decode operation.
DecodeOptions
Options controlling one decode operation.
DecodedImage
One decoded image with owned typed pixels and source metadata.
DecodedMetadata
Metadata describing encoded pixels and orientation handling.
DenseFlowOptions
Integer block-matching controls for dense grayscale optical flow.
DepthConversionOptions
Controls conversion from stored depth values to metric camera coordinates.
DepthMap
Metric or relative dense depth map. Non-positive and non-finite values are invalid.
DescriptorBuffer
Row-major descriptor matrix with a fixed width and explicit scalar kind.
Detection
One scored detection used by class-aware post-processing.
DistanceTransformWorkspace
Reusable host scratch storage for the unit-spacing exact distance transform.
EncodeOptions
Options controlling encoded output.
Essential3
A calibrated two-view epipolar constraint matrix.
EuclideanClusterConfig
Configuration for Euclidean clustering.
EuclideanClusterExtractor
Euclidean region-growing cluster extractor.
EuclideanClusterResult
Result of Euclidean clustering.
ExecutionOutput
Output value paired with the receipt for its execution.
ExecutionReceipt
Account of one algorithm execution.
ExposureFusionOptions
Well-exposedness fusion controls.
FarthestPointSampling
Farthest Point Sampling downsampler.
FarthestPointSamplingConfig
Configuration for FarthestPointSampling.
FastOptions
FAST detector configuration for the standard 9-of-16 radius-three circle.
FeatureMatch
One descriptor correspondence from a query feature to a train feature.
FeatureSet2
Keypoints paired one-to-one with descriptor rows.
FileReceipt
Size and SHA-256 receipt for one local file or URI source.
FlowField
Dense (dx, dy) optical-flow field in pixel units.
FpfhRansacConfig
Configuration for FpfhRansacRegistration.
FpfhRansacRegistration
FPFH + RANSAC global registration.
FrameId
Coordinate frame identifier.
Fundamental3
An uncalibrated two-view epipolar constraint matrix.
GaussianBlurU8Workspace
Reusable scratch storage and fixed-point kernel cache for gaussian_blur_u8_into.
GeometricEstimate
A geometric model paired with one inlier decision and residual per input row.
GicpConfig
Configuration for Generalized ICP (plane-to-plane).
GicpRegistration
Generalized ICP registration.
GpuEuclideanClusterExtractor
GPU-grid-backed Euclidean cluster extractor.
GpuNormalEstimator
GPU-accelerated normal estimator.
GpuRansacPlaneSegmenter
GPU-accelerated RANSAC plane segmenter.
GridSelectionOptions
Controls deterministic spatial distribution of candidate keypoints.
GroundConfig
Configuration for GroundSegmenter.
GroundSegmentation
Result of ground segmentation.
GroundSegmenter
Grid-based ground segmenter.
HarrisOptions
Harris detector configuration.
Homography3
A pixel-to-pixel planar projective transform.
HttpByteSource
Random-access COPC byte source backed by HTTP range requests.
HuberKernel
Huber robust kernel.
IcpConfig
Configuration for point-to-point ICP.
IcpRegistration
Point-to-point ICP registration.
Image
An owning, densely packed, interleaved image.
ImageMetadata
Lightweight semantic metadata carried by images and borrowed views.
ImageRegion
A checked rectangular image region.
ImageView
A read-only, zero-copy image view with an explicit row stride.
ImageViewMut
A mutable, zero-copy interleaved image view with an explicit row stride.
IntegralImage
Summed-area table with a zero top row and left column.
Isometry3
Proper rigid transform: rotation + translation without scale/shear.
IssKeypointConfig
Configuration for IssKeypointDetector.
IssKeypointDetector
Intrinsic Shape Signatures keypoint detector.
IssKeypointResult
Result of ISS keypoint detection.
KdTree
Cache-friendly KD-tree for 3D point clouds.
KdTreeNeighborhood
KD-tree backed neighborhood provider.
Kernel1D
Validated one-dimensional correlation kernel.
Kernel2D
Validated two-dimensional correlation kernel.
Keypoint2
One scale-space image keypoint in pixel coordinates.
LabelImage
Connected-component label image (0 is background).
LetterboxTransform
Mapping between a source image and its letterboxed output.
LucasKanadeOptions
Configuration for sparse Lucas–Kanade tracking.
ManifestValidation
Summary returned after re-hashing every local manifest entry.
MaskRle
Alternating zero/one run lengths, always beginning with a zero run.
Mat3
3x3 matrix stored in row-major order.
Mat4
4x4 matrix stored in row-major order.
MatchOptions
Filtering applied to brute-force descriptor correspondences.
MemoryVideoSource
Deterministic in-memory source used for adapter conformance and replay.
MlsConfig
Configuration for MlsSmoothing.
MlsSmoothing
Moving Least Squares smoothing filter.
MonocularOdometryEstimate
Scale-ambiguous monocular odometry result.
MultiObjectTracker
Deterministic same-class greedy IoU multi-object tracker.
MultiObjectTrackerOptions
IoU tracker controls.
MultiPlaneConfig
Configuration for MultiPlaneSegmenter.
MultiPlaneSegmentation
Result of multi-plane segmentation.
MultiPlaneSegmenter
Sequential RANSAC multi-plane segmenter.
MvpIcpConfig
Configuration for optional ICP in the MVP pipeline.
MvpPipeline
Builder-style MVP pipeline runner.
MvpPipelineConfig
Full configuration for the MVP pipeline.
MvpPipelineReceipt
Execution receipt for the stages of one MVP pipeline run.
MvpPipelineResult
Output of a completed MVP pipeline run.
NdtConfig
Configuration for NDT (Normal Distributions Transform) registration.
NdtRegistration
NDT registration (point-to-distribution).
NearestResizeU8Plan
Reusable source-coordinate plan for packed u8 nearest-neighbor resize.
Neighbor
One neighbor search result.
NeighborGraph
A directed neighborhood graph over a point cloud.
NormalEstimationConfig
Configuration for covariance-based normal estimation.
NormalEstimationResult
Result metadata for normal estimation.
NormalEstimator
Covariance-based normal estimator.
NormalOrientationConfig
Configuration for orient_normals_consistent.
Obb
Oriented bounding box recovered from the principal axes of a cloud.
ObjectImageCorrespondence
One ordered object-to-image correspondence for absolute pose estimation.
ObjectTrack
One deterministic detection track.
OccupancyGrid
A dense 3D grid in row-major (z, y, x) order.
OrbOptions
Multi-scale ORB detector and descriptor configuration.
Padding
Padding applied around an image.
Panorama
Pairwise panorama and its integer world-coordinate origin.
PanoramaOptions
Bounded pairwise panorama settings.
PassThrough
Keeps (or drops) points whose value in a named field falls within a range.
PerspectiveTransform
A source-to-destination projective 2D transform.
PinholeCamera
A pinhole camera with optional Brown–Conrady lens distortion.
PlanarImage
An owning, densely packed planar image.
PlanarImageView
A read-only, zero-copy planar image view with explicit strides.
PlaneModel
Plane model in Hessian form: normal · p + d = 0 with unit normal.
PointCloud
Schema-aware columnar point cloud stored on a device.
PointCloudBuilder
Builds point clouds field-by-field.
PointCorrespondence2
One ordered pixel correspondence from a source image to a target image.
PointField
One column in a point cloud schema.
PointMap
Dense per-pixel XYZ point map. Non-finite triples represent invalid points.
PointSchema
Schema describing the columns of a point cloud.
PointToPlaneIcp
Point-to-plane ICP registration.
PointToPlaneIcpConfig
Configuration for point-to-plane ICP.
Pose3
Pose with optional translation covariance.
PositionReduction
Deterministic global position reduction over a bounded source.
PrimitiveSegmentation
Result of fitting a primitive, partitioning the cloud into inliers/outliers.
Quat
Unit quaternion representing a 3D rotation.
RadiusOutlierConfig
Configuration for RadiusOutlierRemoval.
RadiusOutlierRemoval
Radius Outlier Removal (ROR).
RangeImage
A dense range image in row-major order (row * width + col).
RangeImageConfig
Configuration for range_image.
RansacCylinderSegmenter
RANSAC cylinder segmenter. The input cloud must carry normals.
RansacPlaneConfig
Configuration for RANSAC plane segmentation.
RansacPlaneSegmentation
Result of RANSAC plane segmentation.
RansacPlaneSegmenter
RANSAC-based dominant plane segmenter.
RansacPrimitiveConfig
Shared RANSAC controls for primitive fitting.
RansacSphereSegmenter
RANSAC sphere segmenter.
RectMorphologyWorkspace
Reusable scratch storage for packed grayscale rectangular morphology.
RegionGrowingConfig
Configuration for normal-based region growing segmentation.
RegionGrowingResult
Result of region growing segmentation.
RegionGrowingSegmenter
Normal-based region growing segmenter.
RegistrationResult
Result of a registration run.
RelativePose
Target-camera pose expressed in the source-camera coordinate frame.
RelativePoseEstimate
Essential-matrix pose disambiguation and per-correspondence triangulation.
RgbdOdometryEstimate
Metric previous-camera to current-camera odometry result.
RgbdOdometryOptions
Depth filtering and PnP RANSAC controls for metric RGB-D odometry.
RobustEstimationOptions
Deterministic robust-model sampling and inlier classification settings.
RobustTrackOptions
Forward/backward consistency settings layered over pyramidal LK.
RobustTracks
One target coordinate, validity decision, and round-trip error per source point.
ScoredIndex
Index and possibly updated score returned by Soft-NMS.
ShiTomasiOptions
Shi–Tomasi minimum-eigenvalue detector configuration.
SpatialMetadata
Spatial metadata attached to point clouds and maps.
SpatialTensor
Borrowed chunked view over a PointCloud.
SpatialTensorChunk
One contiguous index range within a SpatialTensor chunk iteration.
SphereModel
Sphere model: all surface points are radius from center.
StandardSchemas
Standard schemas used by typed views and IO adapters.
StatisticalOutlierConfig
Configuration for StatisticalOutlierRemoval.
StatisticalOutlierRemoval
Statistical Outlier Removal (SOR).
StereoBmOptions
Block-matching stereo options.
StereoRectifyMaps
Remap grids produced by stereo rectification for explicit warp::remap.
StereoRig
Calibrated two-camera stereo geometry.
StoragePreflight
Result of a fail-closed output-root free-space check.
StorageRoots
Optional roots used to resolve logical input and output paths.
StreamingVoxelConfig
Configuration for deterministic, spill-backed global voxel centroids.
StreamingVoxelSource
Bounded source of globally aggregated voxel centroids.
StructuringElement
A validated binary neighborhood mask and anchor.
SymmetricEigen3
Result of a symmetric 3x3 eigendecomposition.
Timestamp
Timestamp in nanoseconds since an arbitrary epoch.
TrackedPoints
Result of sparse point tracking between two frames.
TransferStats
Byte accounting for explicit execution transfers.
Transform3
Rigid transform represented as a 4x4 matrix.
TransformAabb
Axis-aligned bounding box.
TriangulatedPoint
One two-view triangulation with cheirality and reprojection diagnostics.
TukeyKernel
Tukey biweight robust kernel.
Vec2
2D vector.
Vec3
3D vector.
Vec4
4D vector.
VideoFrame
Timestamped owned video frame.
VoxelGridConfig
Configuration for voxelize.
VoxelGridDownsample
Voxel-grid downsampling filter.
VoxelGridDownsampleConfig
Configuration for voxel-grid downsampling.

Enums§

AdaptiveThresholdMethod
Adaptive neighborhood statistic.
AlphaMode
Alpha-channel interpretation.
AttributeAggregation
Attribute aggregation policy for non-position fields.
BorderMode
Out-of-bounds sampling behavior for CPU image operations.
CameraError
Camera model errors.
ChunkMapOperation
Per-chunk operation that preserves the input schema.
ColorRange
Numeric range convention associated with image channels.
ColorSpace
Semantic interpretation of image channels.
Connectivity
Pixel connectivity used by binary-mask algorithms.
DType
Supported scalar dtypes for point fields.
DecodedPixels
Owned typed pixels produced by a decoder or accepted by an encoder.
DescriptorKind
Scalar representation used by a descriptor matrix.
DeviceKind
Device kind supported by SpatialRust execution.
ExecutionPolicy
Execution policy for spatial algorithms.
FieldSemantic
Semantic meaning of a point field.
ImageError
Errors raised while constructing or indexing images.
ImageFileFormat
File formats recognized by the stable SpatialRust image-IO boundary.
ImageIoError
Errors produced by bounded image IO.
ImageLayout
Physical channel arrangement in CPU storage.
Interpolation
Sampling filter used by image resampling and geometric warps.
IoError
IO-specific error type for SpatialRust.
LasWriteFormat
Output encoding for LAS writers.
LeastSquaresResult
Result of a small dense linear solve.
MorphologyOperation
Composite morphology operation.
MorphologyShape
Built-in structuring-element geometry.
MvpRegistrationMethod
Registration backend used by the MVP pipeline’s optional alignment step.
OrbScoreType
Response used to rank ORB keypoints.
Orientation
Exif image orientation in encoded-pixel coordinates.
PcdWriteFormat
Output encoding for PCD writers.
PlyWriteFormat
Output encoding for PLY writers.
PointBuffer
Typed column buffer for one point field.
PointCloudFileFormat
Supported point cloud file formats detected from file extensions.
ReceiptRole
Logical role of a file in a dataset operation.
RgbdError
Errors from RGB-D conversion.
RleOrder
Linearization order used by run-length encoded masks.
SoftNmsMethod
Soft-NMS score-decay strategy.
SourceColorType
Encoded sample/channel type before conversion into SpatialRust storage.
SpatialError
Core error type for SpatialRust.
ThresholdType
Point-wise threshold transformation.
TrackState
Track lifecycle state.
TransferDirection
Direction of an explicit data transfer between host and device memory.
UpAxis
Which axis points “up” (its minimum defines local ground height).
VisionError
Errors raised by image and vision algorithms.
VoxelAggregationMode
Voxel aggregation strategy.
VoxelFill
How a voxel’s value is filled from the points that fall in it.

Constants§

DATASET_MANIFEST_VERSION
Current JSON schema version for DatasetManifest.
DEFAULT_GPU_MIN_POINTS_EUCLIDEAN
Minimum point count before GPU Euclidean clustering is selected under Auto.
DEFAULT_GPU_MIN_POINTS_PLANE
Minimum point count before GPU RANSAC plane scoring is selected under Auto.
DEFAULT_MIN_OUTPUT_FREE_BYTES
Initial v1.3 minimum free-space floor for an external output root.
DEFAULT_SPATIAL_TENSOR_CHUNK_SIZE
Default chunk size for PointCloud::spatial_tensor_chunks.
FPFH_DESCRIPTOR_LEN
Length of an FPFH descriptor (33: three 11-bin angular histograms).
INVALID_DISPARITY
Invalid disparity sentinel written by stereo_block_match.
PARALLEL_CHUNK_QUERY_MIN_POINTS
Minimum point count before threaded chunk dispatch is used.
PARALLEL_STAGING_MIN_POINTS
Minimum point count before multi-threaded index staging is used.

Traits§

ChunkedNearestNeighborIndex
k-NN search over contiguous query index ranges.
ChunkedRadiusSearchIndex
Radius search over contiguous query index ranges.
Device
Minimal device abstraction defined in core and extended by spatialrust-gpu.
FeatureEstimator
Computes point-wise features from an input point cloud.
HasIntensity
Capability trait for point clouds with intensity values.
HasNormals3
Capability trait for point clouds with surface normals.
HasPositions3
Capability trait for point clouds with 3D positions.
NearestNeighborIndex
Exact nearest neighbor queries.
NeighborhoodProvider
Neighborhood query abstraction for feature estimation.
PixelComponent
Scalar component supported by generic CPU image kernels.
PointCloudFilter
Point cloud filter interface.
PointCloudRegistration
Common trait for point cloud registration algorithms.
PointCloudSegmenter
Common trait for point cloud segmentation algorithms.
RadiusSearchIndex
Radius search queries.
Real
Floating-point scalar used by spatial algorithms.
RobustKernel
Robust loss kernel used by registration and estimation algorithms.
Scalar
Numeric types supported by SpatialRust math primitives.
SpatialAlgorithm
Common trait implemented by spatial algorithms.
SpatialIndex
Common spatial index operations.
SpatialRuntime
Runtime boundary for executing spatial algorithms on one backend.
TransformPoint
Trait for types that can transform 3D points.
VideoFrameSource
Pull-based video source implemented by optional codec/camera adapters.

Functions§

adaptive_threshold
Applies adaptive binary thresholding to an 8-bit grayscale image.
apply_transform
Applies a 4×4 affine transform to a cloud’s positions (and normals, if present — normals are rotated by the linear part and renormalized).
approx_eq
Returns whether two values are approximately equal.
approx_eq_f64
Returns whether two values are approximately equal.
approximate_polygon
Simplifies a closed contour with Ramer–Douglas–Peucker approximation.
batched_nms
Class-aware greedy NMS over detection records.
bilateral_filter
Applies an edge-preserving bilateral filter.
bounding_box
Axis-aligned bounding box of a cloud.
box_blur
Applies a normalized rectangular box filter.
brute_force_knn
Finds up to k nearest neighbors by brute force.
brute_force_radius
Finds all neighbors within radius by brute force.
build_gaussian_pyramid
Builds a packed Gaussian pyramid including the input as level zero.
canny
Finds edges in a single-channel u8 image.
canny_into
Finds edges into caller-owned output using reusable CPU workspace.
canny_with_intermediates
Runs Canny and retains gradient, magnitude, and suppression stages.
centroid
Centroid (mean position) of a cloud.
chamfer_distance
Symmetric Chamfer distance between two clouds (sum of mean squared NN distances in both directions). Lower is better; zero for identical clouds.
clahe
Applies contrast-limited adaptive histogram equalization to grayscale u8.
cloud_distances
Computes directed NN distance statistics between a and b in both directions with a single KD-tree per side.
connected_components
Labels foreground components and computes bounding boxes and centroids.
connected_components_u8
Labels connected non-zero pixels from packed u8 mask storage.
convolve2d
Applies true convolution by reversing the supplied kernel around its anchor.
copc_level_for_resolution
Computes the shallowest octree level whose spacing is at most resolution.
crop
Copies a checked rectangular region into a packed image.
decode_bytes
Decodes an image from an encoded byte slice.
decode_path
Opens and decodes one image path using content-based format detection.
decode_reader
Reads a bounded encoded stream and decodes it.
decode_rle
Decodes a run-length mask and validates its total length.
dense_flow_block_match
Computes a dense integer flow field with deterministic local block matching.
depth_map_to_point_cloud
Unprojects a depth map with a calibrated camera into an XYZ point cloud.
depth_tensor_to_depth_map
Converts a host depth tensor into a DepthMap.
depth_to_point_cloud
Converts an aligned depth image into an XYZ point cloud.
depth_to_xyz_dense
Converts depth into a dense H×W×3 XYZ buffer (row-major interleaved).
depth_to_xyz_dense_into
Fills a caller-provided dense H×W×3 XYZ buffer (length must be H*W*3).
detect_and_describe_orb
Detects oriented multi-scale keypoints and computes 256-bit rotated BRIEF descriptors.
detect_fast
Detects FAST-9/16 corners in scan order, matching OpenCV’s radius-three ROI.
detect_harris
Detects Harris corners and returns strongest-first keypoints.
detect_point_cloud_format
Detects a point cloud format from a file path extension.
detect_shi_tomasi
Detects Shi–Tomasi corners and returns strongest-first keypoints.
detection_tensor_to_detections
Decodes axis-aligned detections from an [N,6] tensor of x0,y0,x1,y1,score,class.
dilate
Dilates each channel independently.
dilate_rect_u8
Dilates a grayscale u8 image with a rectangular element in linear time.
dilate_rect_u8_into
Dilates into caller-owned packed output using reusable scratch storage.
disparity_to_depth
Converts horizontal disparity to metric depth with Z = f * B / d.
disparity_to_xyz
Reprojects disparity into left-camera XYZ using rectified intrinsics.
distance_transform_edt
Computes the exact Euclidean distance from every foreground pixel to the nearest background pixel using unit pixel spacing.
distance_transform_edt_into
Computes the exact unit-spacing Euclidean distance transform into a reusable slice.
distance_transform_edt_u8_into
Computes a unit-spacing exact distance transform from a packed u8 mask.
distance_transform_edt_with_spacing
Computes the exact Euclidean distance transform with physical pixel spacing.
encode_bytes
Encodes typed pixels into an owned byte vector.
encode_path
Creates or truncates a path and encodes typed pixels into it.
encode_rle
Encodes a binary mask into alternating runs.
encode_writer
Encodes typed pixels to a seekable writer.
equalize_histogram
Equalizes an 8-bit grayscale histogram.
erode
Erodes each channel independently.
erode_rect_u8
Erodes a grayscale u8 image with a rectangular element in linear time.
erode_rect_u8_into
Erodes into caller-owned packed output using reusable scratch storage.
estimate_and_stitch_panorama
Estimates a source-to-target homography and stitches the pair.
estimate_essential
Estimates an essential matrix after normalizing pixels with both cameras.
estimate_essential_ransac
Robustly estimates an essential matrix in normalized-camera coordinates.
estimate_fundamental
Estimates a fundamental matrix from at least eight correspondences.
estimate_fundamental_ransac
Robustly estimates a fundamental matrix using deterministic eight-point RANSAC.
estimate_homography
Estimates a homography from at least four correspondences using normalized DLT.
estimate_homography_ransac
Robustly estimates a homography using deterministic four-point RANSAC.
estimate_monocular_odometry
Estimates calibrated monocular motion with essential RANSAC and cheirality.
estimate_rgbd_odometry
Estimates metric motion from source depth and source-to-target pixel tracks.
estimate_rigid_transform
Estimates the rigid transform that best maps source onto target.
extract_indices
Extracts a sub-cloud containing only the selected point indices.
extract_mask
Extracts points where mask[index] is true.
f32_eps
Default tolerance for f32 comparisons.
f64_eps
Default tolerance for f64 comparisons.
filter2d
Applies OpenCV-style correlation and converts the result back to the input dtype.
filter2d_f32
Applies OpenCV-style correlation and preserves signed/fractional results as f32.
find_contours
Extracts oriented boundary loops, including hole contours.
fpfh_descriptors
Computes an FPFH descriptor for every point in cloud.
fuse_exposures
Fuses aligned RGB exposures with normalized per-pixel well-exposedness.
gaussian_blur
Applies a separable Gaussian blur with explicit odd sizes and standard deviations.
gaussian_blur_u8
Applies a specialized 3×3, 5×5, or 7×7 Gaussian blur to interleaved u8 input.
gaussian_blur_u8_into
Applies the specialized u8 Gaussian blur into caller-owned packed output and workspace.
gray_to_rgb
Replicates a gray channel into RGB.
gray_world_white_balance
Applies deterministic gray-world white balance to an RGB image.
harris_response
Computes an unnormalized Harris structure-tensor response image.
hausdorff_distance
Symmetric Hausdorff distance between two clouds (the largest NN distance in either direction). Captures the worst-case discrepancy.
histogram
Computes a configurable one-channel histogram, optionally through a mask.
histogram_u8
Computes the exact 256-bin histogram of an 8-bit grayscale image.
integral_image
Computes a summed-area table for one selected channel.
knn_graph
Builds a directed k-nearest-neighbor graph: an edge from every point to each of its k nearest neighbors (excluding itself).
laplacian
Computes a Laplacian response as signed f32 values.
letterbox
Aspect-preserving resize followed by centered constant padding.
match_descriptors
Matches each query descriptor to its nearest train descriptor.
median_blur
Applies a per-channel median filter with an odd square aperture.
merge_clouds
Concatenates clouds that share an identical schema into one cloud.
morphology_ex
Applies a composite morphology operation.
morphology_rect_u8
Applies composite grayscale u8 morphology using the rectangular fast path.
morphology_rect_u8_into
Applies composite rectangular morphology into caller-owned packed output.
nearest_k_spatial_tensor
Runs k-NN search for every chunk in a SpatialTensor, appending tagged neighbors.
nearest_k_spatial_tensor_parallel
Parallel k-NN search over SpatialTensor chunks.
nearest_k_spatial_tensor_parallel_into
Parallel k-NN search, appending (query_index, neighbor) pairs to out.
nms
Greedy non-maximum suppression. Returned indices are score-descending.
normalize
Converts packed scalar values to f32, then applies value * scale, mean subtraction, and per-channel standard-deviation normalization.
normalize_into
Normalizes interleaved pixels into caller-owned f32 storage.
normalize_unit_sphere
Recenters a cloud and scales it so its farthest point is at unit distance — the canonical normalization for learned point-cloud models.
orient_normal_towards_viewpoint
Orients a normal to point towards the viewpoint when possible.
orient_normals_consistent
Re-orients a cloud’s normals so neighboring normals agree in sign.
oriented_bounding_box
Oriented bounding box via principal component analysis of the positions.
otsu_threshold_u8
Selects an Otsu threshold for an 8-bit grayscale image and applies it.
otsu_threshold_u16
Selects an Otsu threshold for a 16-bit grayscale image and applies it.
pack_chw
Packs and normalizes an interleaved image into planar CHW storage.
pack_chw_into
Packs and normalizes interleaved pixels into a reusable planar CHW slice.
pad
Pads an image with a constant pixel value.
parallel_index_for_each
Runs work over disjoint index ranges using parallel_worker_count.
parallel_index_ranges
Returns disjoint half-open index ranges covering [0, point_count).
parallel_worker_count
Returns the number of worker threads to use for point_count points.
planar_f32_to_nchw
Packs a planar CHW f32 image into contiguous NCHW [1,C,H,W].
point_map_to_point_cloud
Flattens valid point-map pixels into an XYZ cloud, optionally filtering by confidence.
project_object_point
Projects an object point with an absolute pose into pixel coordinates.
pyr_down
Reduces each dimension by approximately two using the canonical 5×5 kernel.
pyr_up
Doubles each dimension using zero insertion and the canonical 5×5 kernel.
radius_graph
Builds a directed radius graph: an edge from every point to each other point within radius.
radius_search_spatial_tensor
Runs radius search for every chunk in a SpatialTensor, appending tagged neighbors.
radius_search_spatial_tensor_parallel
Parallel radius search over SpatialTensor chunks.
radius_search_spatial_tensor_parallel_into
Parallel radius search, appending (query_index, neighbor) pairs to out.
range_image
Projects a cloud into a spherical range image, keeping the nearest range per pixel. Points outside the vertical field of view are dropped.
read_copc
Reads all points from a COPC file on disk.
read_copc_file
Reads all points from a COPC file on disk.
read_copc_file_in_bounds
Reads points inside a bounding box at full available detail.
read_copc_file_info
Reads COPC header metadata without loading points.
read_copc_file_with_query
Reads points using a spatial bounds and optional LOD limit.
read_copc_url
Reads all points from a remote COPC URL.
read_copc_url_info
Reads COPC header metadata from a remote URL without loading points.
read_copc_url_with_query
Reads points from a remote COPC URL using an optional spatial query.
read_e57
Reads all scans from an E57 file and merges them into one point cloud.
read_e57_file
Reads all scans from an E57 file and merges them into one point cloud.
read_las
Reads a complete LAS/LAZ stream.
read_las_file
Reads a LAS/LAZ file from disk.
read_pcd
Reads a complete PCD file from any buffered reader.
read_pcd_file
Reads a PCD file from disk.
read_ply
Reads a complete PLY file from any buffered reader.
read_ply_file
Reads a PLY file from disk.
read_point_cloud_file
Reads a point cloud from disk, dispatching on the file extension.
read_point_cloud_file_with_format
Reads a point cloud using an explicit format.
recenter
Translates a cloud so its centroid sits at the origin.
recover_relative_pose
Recovers the essential-matrix pose with the most positive-depth points.
reduce_positions
Consumes a source and computes bounds and centroid without retaining chunks.
remap
Samples an image at absolute coordinates supplied by two single-channel maps.
resize
Resizes an interleaved image while preserving semantic metadata.
resize_into
Resizes into caller-owned storage without allocating.
resize_pack_chw
Fuses bilinear RGB resize, normalization, and CHW packing without an intermediate image.
resize_pack_chw_into
Fuses bilinear RGB resize, normalization, and CHW packing into caller-owned storage.
resize_rgb_to_gray
Fuses bilinear RGB resize and BT.601 grayscale conversion without an intermediate RGB image.
resize_rgb_to_gray_into
Fuses bilinear RGB resize and BT.601 grayscale conversion into caller-owned storage.
rgb_to_gray
Converts RGB u8 pixels to BT.601 luma using fixed-point coefficients.
rgb_to_gray_into
Converts RGB u8 pixels into caller-owned gray storage without allocating.
rgb_to_hsv
Converts RGB u8 to OpenCV-style HSV (H in 0..=179, S/V in 0..=255).
rgb_u8_to_nchw_f32
Letterboxes an RGB u8 image and packs it as contiguous NCHW f32 [1,3,H,W].
rgbd_to_point_cloud
Converts aligned RGB and depth images into an XYZRGB point cloud.
scale_cloud
Uniformly scales a cloud about the origin by factor.
scharr
Computes a 3×3 Scharr first derivative as signed f32 values.
score_tensor_to_binary_mask
Converts a host score tensor into a binary mask via threshold.
select_keypoints_grid
Retains the strongest keypoints in each image cell.
separable_filter
Applies horizontal and vertical kernels using an f64 intermediate buffer.
separable_filter_f32
Applies separable kernels and preserves signed/fractional output as f32.
shi_tomasi_response
Computes an unnormalized Shi–Tomasi minimum-eigenvalue response image.
smallest_eigenvector
Returns the eigenvector for the smallest eigenvalue.
sobel
Computes a Sobel derivative as signed f32 values.
sobel_3x3_u8
Computes a first-order 3x3 Sobel derivative directly into signed f32 output.
sobel_3x3_u8_into
Computes a first-order 3x3 Sobel derivative into caller-owned packed output.
sobel_abs_3x3_u8
Computes an exact absolute first-order 3x3 Sobel response as saturated u8.
sobel_abs_3x3_u8_into
Computes an exact absolute first-order 3x3 Sobel response into packed output.
sobel_l1_magnitude_u8
Computes exact 3×3 Sobel L1 magnitude (|Gx| + |Gy|) for grayscale u8.
sobel_l1_magnitude_u8_into
Computes exact fused 3×3 Sobel L1 magnitude into caller-owned packed output.
sobel_threshold_3x3_u8
Computes a binary edge mask from absolute 3x3 Sobel response.
sobel_threshold_3x3_u8_into
Computes a binary absolute-Sobel edge mask into caller-owned packed output.
soft_nms
Soft non-maximum suppression with deterministic score ordering.
solve_linear_system
Solves A x = b for square n x n systems using Gaussian elimination with partial pivoting.
solve_pnp
Estimates an object-to-camera pose from at least four correspondences.
solve_pnp_ransac
Robust PnP using deterministic six-point RANSAC and inlier refinement.
spatial_gradient_u8
Computes exact 3×3 Sobel X/Y gradients together for grayscale u8 input.
spatial_gradient_u8_into
Computes exact paired 3×3 Sobel gradients into caller-owned packed output.
stereo_block_match
Dense SAD block matching on already-rectified grayscale stereo images.
stereo_rectify
Builds left/right absolute remap grids that make epipolar lines horizontal.
stitch_panorama_pair
Warps source into target coordinates and feather-blends their overlap.
swap_red_blue
Swaps the red and blue channels of a three-channel image.
symmetric_eigen3
Computes eigenvalues and eigenvectors of a symmetric 3x3 matrix.
threshold
Applies a fixed threshold independently to every component.
track_points_forward_backward
Tracks points in both directions and rejects inconsistent round trips.
track_points_lucas_kanade
Tracks sparse points from previous to next with pyramidal Lucas–Kanade.
transform_point_cloud
Applies a rigid transform to point positions and normals in a point cloud copy.
triangulate_correspondence
Triangulates one calibrated correspondence for a known relative pose.
voxelize
Voxelizes a cloud into a dense occupancy / count grid.
warp_affine
Warps an image with a source-to-destination affine transform.
warp_perspective
Warps an image with a source-to-destination projective transform.
with_labels
Adds or replaces a per-point label field on a point cloud copy.
write_copc
Writes a point cloud to a COPC file on disk.
write_copc_file
Writes a point cloud to a COPC file on disk.
write_copc_file_with_params
Writes a point cloud to a COPC file using custom octree builder parameters.
write_e57
Writes a point cloud to an E57 file on disk.
write_e57_file
Writes a point cloud to an E57 file on disk.
write_las
Writes a point cloud to a LAS/LAZ stream and returns the inner writer.
write_las_file
Writes a point cloud to a LAS/LAZ file on disk.
write_pcd
Writes a point cloud to a PCD stream.
write_pcd_file
Writes a point cloud to a PCD file on disk.
write_ply
Writes a point cloud to a PLY stream.
write_ply_file
Writes a point cloud to a PLY file on disk.
write_point_cloud_file
Writes a point cloud to disk, dispatching on the file extension.
write_point_cloud_file_with_format
Writes a point cloud using an explicit format.

Type Aliases§

ChunkQueryRange
Range of query point indices (matches SpatialTensor::chunks ranges).
FpfhDescriptor
A single FPFH descriptor.
GrayImage
A one-channel image.
RgbImage
A three-channel RGB image.
SpatialResult
Result type used across SpatialRust crates.
VisionResult
Result type for image and vision operations.