FixedPoints
¶
Bases: BaseTransform
Samples a fixed number of points (nodes) from a point cloud, with all
their node-level attributes (with mx.random). Edges are left
unchanged, as in PyG.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
num
|
int
|
The number of points to sample. |
required |
replace
|
bool
|
If |
True
|
allow_duplicates
|
bool
|
Without replacement, whether to repeat points when
|
False
|
Example:
Source code in mlx_graphs/transforms/point_cloud.py
from mlx_graphs.transforms import FixedPoints · mlx_graphs/transforms/point_cloud.py