mlx3d.splatting¶
mlx3d.splatting
¶
GaussianModel
¶
A scene of 3D Gaussians with the standard 3DGS parameterization.
Raw (unconstrained) parameters live in self.params so they can be fed
to MLX optimizers directly:
means(N, 3)scales(N, 3): log of the per-axis standard deviations.quats(N, 4): unnormalized rotation quaternions (w, x, y, z).opacities(N,): logits; sigmoid gives opacity.sh_dc(N, 1, 3) andsh_rest(N, K-1, 3): SH color coefficients.
Source code in src/mlx3d/splatting/model.py
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 | |
from_points(points, colors=None, sh_degree=3, initial_opacity=0.1, scale_init_max_ref=10000, scale_init_chunk_size=1024, scale_init_max_scale=None)
classmethod
¶
Initialize from a point cloud (e.g. SfM points).
Scales are set from the mean distance to the 3 nearest neighbors, as in the reference implementation.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
scale_init_max_ref
|
int
|
Maximum reference points used for the initial nearest-neighbor scale estimate. Large COLMAP clouds otherwise spend seconds to minutes materializing huge distance tiles. |
10000
|
scale_init_chunk_size
|
int
|
Query chunk size for the scale-estimation KNN. Lower values reduce peak memory during initialization. |
1024
|
scale_init_max_scale
|
float | None
|
Optional cap for initial per-axis Gaussian scale. This is useful for COLMAP point clouds with sparse outliers whose nearest-neighbor distances would otherwise create full-screen splats. |
None
|
Source code in src/mlx3d/splatting/model.py
36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 | |
apply_2dgs_constraints(max_thickness)
¶
Constrain Gaussians to thin surfels for 2DGS-style training.
The covariance projection and rasterizer already support anisotropic oriented Gaussians. Keeping the third local scale small turns each Gaussian into an oriented disk while preserving standard 3DGS PLY compatibility.
Source code in src/mlx3d/splatting/model.py
128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 | |
render_features(camera, features, background=None, normalize=False, antialias=False, projection='ewa')
¶
Render arbitrary per-Gaussian feature channels from this model.
Source code in src/mlx3d/splatting/model.py
182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 | |
surfel_points(min_opacity=0.01, max_points=None, orient_towards=None)
¶
Return oriented surfel samples from the Gaussian centers.
This is intended for 2DGS-style checkpoints, where the local z axis
is the surfel normal and the first two local scales span the disk. Rows
are filtered by activated opacity and, when capped, ranked by
opacity * scale_x * scale_y so large opaque surfels survive first.
Source code in src/mlx3d/splatting/model.py
210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 | |
extract_surface_mesh(resolution=64, padding=0.1, min_opacity=0.01, max_points=200000, orient_towards=None)
¶
Reconstruct a mesh from oriented Gaussian surfels via Poisson reconstruction.
Source code in src/mlx3d/splatting/model.py
252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 | |
copy()
¶
Return a detached copy of the Gaussian table.
Source code in src/mlx3d/splatting/model.py
273 274 275 276 277 | |
compact(min_opacity=0.0, max_gaussians=None, target_sh_degree=None)
¶
Return a smaller checkpoint by pruning low-importance Gaussians.
Importance is a conservative, view-independent proxy:
sigmoid(opacity) * max(scale)^2. This keeps opaque large-footprint
splats before transparent/subpixel ones, preserves the original order
of retained rows for checkpoint diffability, and does not mutate this
model.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
min_opacity
|
float
|
prune Gaussians with activated opacity below this threshold. If the threshold removes every row, the most important Gaussian is kept so the checkpoint remains renderable. |
0.0
|
max_gaussians
|
int | None
|
optional hard cap; the highest-importance rows are retained. |
None
|
target_sh_degree
|
int | None
|
optional lower SH degree for color coefficient truncation. This reduces checkpoint size and render cost for view-dependent color at the expense of angular detail. |
None
|
Source code in src/mlx3d/splatting/model.py
279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 | |
save_ply(path)
¶
Save in the standard 3DGS PLY layout (compatible with most viewers).
Source code in src/mlx3d/splatting/model.py
338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 | |
load_ply(path, sh_degree=3)
classmethod
¶
Load a 3DGS-format PLY checkpoint.
Source code in src/mlx3d/splatting/model.py
363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 | |
select(keep_idx)
¶
Keep only the Gaussians at keep_idx (in-place).
Source code in src/mlx3d/splatting/model.py
395 396 397 398 | |
append(new_params)
¶
Concatenate new Gaussians (in-place).
Source code in src/mlx3d/splatting/model.py
400 401 402 403 404 | |
densify_and_prune(grad_accum, grad_count, grad_threshold=0.0002, scene_extent=1.0, percent_dense=0.01, min_opacity=0.005, return_optimizer_state=False)
¶
Adaptive density control from the 3DGS paper.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
grad_accum
|
array
|
(N,) accumulated NDC-space positional gradient norms. |
required |
grad_count
|
array
|
(N,) number of accumulation steps each Gaussian was visible. |
required |
Under-reconstructed regions (high positional gradient, small scale) are cloned; over-reconstructed ones (high gradient, large scale) are split in two. Nearly transparent or oversized Gaussians are pruned. Returns counts of cloned/split/pruned Gaussians.
Source code in src/mlx3d/splatting/model.py
406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 | |
relocate_mcmc(grad_accum, grad_count, relocate_frac=0.02, min_opacity=0.01, jitter_scale=0.25)
¶
Fixed-budget MCMC-style relocation of underused Gaussians.
This keeps N constant: low-opacity or never-visible rows are
replaced by jittered copies of high-gradient rows. It is inspired by
MCMC 3DGS relocation, and is intended as an alternative to vanilla
clone/split/prune density control.
Source code in src/mlx3d/splatting/model.py
482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 | |
reset_opacities(max_opacity=0.01)
¶
Clamp opacities down (periodic reset from the 3DGS paper).
Source code in src/mlx3d/splatting/model.py
533 534 535 536 537 538 | |
GaussianTrainer
¶
Optimizes a :class:GaussianModel against posed images.
Source code in src/mlx3d/splatting/trainer.py
78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 | |
learning_rates()
¶
Current per-parameter Adam learning rates.
Source code in src/mlx3d/splatting/trainer.py
130 131 132 | |
step(camera, target)
¶
One optimization step on a single view. Returns logging info.
Source code in src/mlx3d/splatting/trainer.py
319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 | |
TrainerConfig
dataclass
¶
Source code in src/mlx3d/splatting/trainer.py
27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 | |
method = 'vanilla'
class-attribute
instance-attribute
¶
Training strategy: vanilla, mcmc, or 2dgs.
antialias = False
class-attribute
instance-attribute
¶
Use Mip-Splatting-style opacity compensation for projection blur.
projection = 'ewa'
class-attribute
instance-attribute
¶
Gaussian projection method: ewa or 3DGUT-style ut.
lambda_2d_depth_variance = 0.0
class-attribute
instance-attribute
¶
2DGS-only ray-depth variance penalty; encourages one surface per pixel.
lambda_2d_normal_consistency = 0.0
class-attribute
instance-attribute
¶
2DGS-only loss between rendered surfel normals and depth-map normals.
geometry_min_alpha = 0.05
class-attribute
instance-attribute
¶
Minimum alpha for pixels included in 2DGS geometry losses.
mcmc_relocate_frac = 0.02
class-attribute
instance-attribute
¶
Max fraction of Gaussians relocated at each MCMC density event.
mcmc_min_opacity = 0.01
class-attribute
instance-attribute
¶
Rows below this opacity are considered relocation targets in MCMC mode.
mcmc_jitter_scale = 0.25
class-attribute
instance-attribute
¶
Relocated copies are jittered by this multiple of their source scale.
mcmc_noise_scale = 0.01
class-attribute
instance-attribute
¶
Per-step SGLD-like xyz noise scale used in MCMC mode.
two_d_thickness = 0.0001
class-attribute
instance-attribute
¶
2DGS local-normal thickness as a fraction of scene extent.
max_gaussians = None
class-attribute
instance-attribute
¶
Stop clone/split growth above this count (pruning continues).
low_memory = False
class-attribute
instance-attribute
¶
Cap MLX's buffer cache and clear it after densification events. Reduces peak memory noticeably on 8-16 GB machines at a small speed cost.
cache_limit_gb = 2.0
class-attribute
instance-attribute
¶
MLX buffer-cache cap used when low_memory is enabled.
project_gaussians(camera, means, quats, scales, blur=0.3, antialias=False)
¶
Project 3D Gaussians into screen space.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
camera
|
Camera
|
the viewing :class: |
required |
means
|
array
|
(N, 3) Gaussian centers in world space. |
required |
quats
|
array
|
(N, 4) rotations (w, x, y, z), need not be normalized. |
required |
scales
|
array
|
(N, 3) per-axis standard deviations. |
required |
blur
|
float
|
screen-space dilation added to the diagonal (0.3 px as in 3DGS, which guarantees splats cover at least about one pixel). |
0.3
|
antialias
|
bool
|
if |
False
|
Returns:
| Type | Description |
|---|---|
dict[str, array]
|
dict with:
- |
Source code in src/mlx3d/splatting/projection.py
24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 | |
project_gaussians_ut(camera, means, quats, scales, blur=0.3, antialias=False)
¶
Project Gaussians with a 3D Unscented Transform.
This 3DGUT-style projection sends six cubature sigma points through the
camera's actual :meth:~mlx3d.cameras.Camera.project_points method, so
Brown-Conrady distortion, fisheye distortion, and orthographic cameras are
handled by the same camera model used elsewhere in the library. It is more
expensive than the analytic EWA projection and is therefore opt-in.
Source code in src/mlx3d/splatting/projection.py
149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 | |
quat_scale_to_cov3d(quats, scales)
¶
Build 3D covariances R S S^T R^T from quaternions (N, 4) and scales (N, 3).
Source code in src/mlx3d/splatting/projection.py
17 18 19 20 21 | |
rasterize_depth(means2d, conics, opacities, depths, sorted_ids, tile_ranges, width, height, tiles_x, tiles_y)
¶
Forward-only expected depth rasterization for viewer/diagnostic modes.
Source code in src/mlx3d/splatting/rasterize.py
548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 | |
rasterize_features(means2d, conics, features, opacities, sorted_ids, tile_ranges, width, height, tiles_x, tiles_y, background=None, normalize=False)
¶
Alpha-composite arbitrary per-Gaussian feature channels.
This reuses the optimized RGB forward/backward Metal kernels in chunks of
three channels. It is intentionally memory-bounded: only one (H, W, 3)
output is materialized per chunk, while MLX autodiff sums gradients from
each chunk back into the shared Gaussian parameters.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
features
|
array
|
|
required |
background
|
array | None
|
optional |
None
|
normalize
|
bool
|
if |
False
|
Returns:
| Type | Description |
|---|---|
dict[str, array]
|
dict with |
dict[str, array]
|
auxiliary buffers |
Source code in src/mlx3d/splatting/rasterize.py
449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 | |
render_gaussians_reference(camera, means, quats, scales, opacities, colors, background=None, antialias=False)
¶
Reference renderer matching :func:mlx3d.splatting.render_gaussians.
Source code in src/mlx3d/splatting/reference.py
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 | |
render_gaussian_depth(camera, means, quats, scales, opacities, refine_tiles=False, antialias=False, projection='ewa')
¶
Render expected depth and alpha from 3D Gaussians.
This is a forward-only diagnostic/viewer path. It uses the same projection, tile binning, and alpha compositing math as RGB splatting, but accumulates transmittance-weighted depth instead of color.
Source code in src/mlx3d/splatting/render.py
115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 | |
render_gaussian_features(camera, means, quats, scales, opacities, features, background=None, normalize=False, refine_tiles=False, antialias=False, projection='ewa')
¶
Render arbitrary per-Gaussian feature channels.
render_gaussians is specialized for RGB color. This function exposes
the same projection/binning/rasterization path for any (N, C) feature
tensor: depth-like scalars, normals, semantic logits, learned embeddings,
or auxiliary training buffers.
Set normalize=True to return expected features divided by accumulated
alpha, matching the expected-depth convention. Leave it False for
ordinary alpha compositing with an optional feature-space background.
Source code in src/mlx3d/splatting/render.py
164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 | |
render_gaussians(camera, means, quats, scales, opacities, colors=None, sh=None, sh_degree=3, background=None, refine_tiles=False, antialias=False, projection='ewa')
¶
Render 3D Gaussians from a camera. Differentiable end to end.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
camera
|
Camera
|
viewing camera. |
required |
means
|
array
|
(N, 3) Gaussian centers. |
required |
quats
|
array
|
(N, 4) rotations (w, x, y, z). |
required |
scales
|
array
|
(N, 3) per-axis standard deviations (positive; apply your
activation, e.g. |
required |
opacities
|
array
|
(N,) in [0, 1] (apply sigmoid before calling). |
required |
colors
|
array | None
|
(N, 3) RGB in [0, 1]. Mutually exclusive with |
None
|
sh
|
array | None
|
(N, K, 3) spherical-harmonic coefficients (K >= (sh_degree+1)^2); view-dependent color is evaluated per Gaussian toward the camera. |
None
|
background
|
array | None
|
(3,) background color (default black). |
None
|
refine_tiles
|
bool
|
experimental conservative ellipse/tile rejection after square radius binning. Off by default because its extra MLX work is not faster on all scenes. |
False
|
antialias
|
bool
|
enable Mip-Splatting-style opacity compensation for the projection blur. This reduces over-bright subpixel splats while preserving the existing 3DGS-compatible behavior by default. |
False
|
projection
|
str
|
|
'ewa'
|
Returns:
| Type | Description |
|---|---|
dict[str, array]
|
dict with |
dict[str, array]
|
outputs ( |
dict[str, array]
|
bookkeeping. |
Source code in src/mlx3d/splatting/render.py
29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 | |
eval_sh(degree, sh, dirs)
¶
Evaluate SH at unit directions.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
degree
|
int
|
SH degree in [0, 3]. |
required |
sh
|
array
|
(N, K, C) coefficients with K >= (degree+1)^2. |
required |
dirs
|
array
|
(N, 3) unit view directions. |
required |
Returns:
| Type | Description |
|---|---|
array
|
(N, C) colors, offset by +0.5 (callers should clamp to >= 0). |
Source code in src/mlx3d/splatting/sh.py
41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 | |
rgb_to_sh(rgb)
¶
Convert RGB in [0, 1] to the DC spherical-harmonic coefficient.
Source code in src/mlx3d/splatting/sh.py
31 32 33 | |
sh_to_rgb(sh_dc)
¶
Convert the DC coefficient back to RGB.
Source code in src/mlx3d/splatting/sh.py
36 37 38 | |
bin_gaussians(means2d, radii, depths, width, height, conics=None)
¶
Assign Gaussians to screen tiles and sort by (tile, depth).
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
means2d
|
array
|
(N, 2) pixel-space centers. |
required |
radii
|
array
|
(N,) pixel radii; 0 means culled. |
required |
depths
|
array
|
(N,) camera-space depths. |
required |
conics
|
array | None
|
optional (N, 3) inverse 2D covariance upper-triangular
coefficients |
None
|
Returns:
| Type | Description |
|---|---|
array
|
|
array
|
is (D,) int32 Gaussian indices for all duplicates in render order and |
int
|
|
int
|
into |
Source code in src/mlx3d/splatting/tiles.py
19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 | |