ravel_3d¶
- torch_sim.transforms.ravel_3d(idx_3d, shape)[source]¶
Convert 3D indices into linear indices for an array of given shape.
This function takes 3D indices, which are typically used to reference elements in a 3D array, and converts them into linear indices. The linear index is calculated based on the provided shape of the array, allowing for easy access to elements in a flattened representation.