Introduction
This is the PLY layout that the
3D Gaussian
Splatting training code from Inria writes when it saves a scene, as
point_cloud.ply. Most splat tools read and write it, and it is the
usual starting point for converting a scene to
.splat, .ksplat, .spz or the compressed PLY.
Each splat is a vertex. Its properties are the model’s parameters as training leaves them, so a reader applies the same functions the renderer does: the exponential to the scales, the sigmoid to the opacity, and normalisation to the rotation.
Structure
The file is a PLY file with a text header and binary
data. The training code writes the data in the computer’s own byte order, which in
practice is little-endian. The header declares one element, vertex, whose count
is the number of splats, and its properties, all float, in this order.
With spherical harmonics of degree 3 there are 62 properties, 248 bytes a splat.
0Headerply,format binary_little_endian 1.0,element vertexn, the property lines,end_headertext…Splats one vertex each248 bytes each at degree 3+0x y z position12 bytes+12nx ny nz normal, written as zero12 bytes+24f_dc_0 to f_dc_2 base colour coefficients12 bytes+36f_rest_0 to f_rest_44 higher spherical harmonics180 bytes+216opacity before the sigmoid4 bytes+220scale_0 to scale_2 log scales12 bytes+232rot_0 to rot_3 quaternion w, x, y, z16 bytes
A reader should find the properties by name rather than by position: other programs
write the same names with fewer f_rest properties, without the normals,
or with extra properties.
In this reference
- Splat properties – every vertex property, and how each becomes part of a Gaussian: sigmoid opacity, exp scale, normalised quaternion and the spherical harmonics
Also used for
- PlayCanvas compressed PLY – Chunks of 256 splats with ranges, and four packed words a splat.
- Polygon File Format – Stanford’s mesh and point cloud format, with a header that declares every property.
Variants
- 3D Gaussian Splatting PLY – the training code’s layout: one float vertex a splat, 248 bytes at degree 3
- PlayCanvas compressed PLY – chunks of 256 splats with ranges, and four packed words a splat
Links
Software
- SuperSplat – PlayCanvas’s free open source splat editor (web)
- GaussianSplats3D – three.js viewer that loads this layout (web)
Developers
- gaussian-splatting – Inria’s training and viewing code, which writes the layout (Python, C++, CUDA)
- plyfile – reads and writes PLY with NumPy (Python)
Reference
- gaussian_model.py – the code that saves and loads the PLY file
- 3D Gaussian Splatting for Real-Time Radiance Field Rendering – the paper’s page at Inria