TECHNOLOGY

Mitsuba depth labels: distinguish pinhole distance from camera-axis depth

In this article
THE QUICK TAKE

Pinhole distance and optical-axis depth differ away from the center of a perspective image.

Begin with the learning target

A depth model can learn distance along a viewing ray or a coordinate along the camera’s forward axis. These quantities agree for a surface directly in front of the camera center, which can hide a dataset mistake during a casual inspection. State the target convention before producing labels. Also specify whether invalid observations use a separate mask, a reserved value or another explicit representation.

Read the renderer’s measurement

The integrator reference describes the depth AOV as distance from the pinhole. Do not rename that output camera-axis depth without a geometric conversion. For a perspective camera and a unit viewing direction, projecting the distance onto the camera’s forward direction produces the corresponding axial coordinate. This interpretation requires consistent camera transforms and a documented direction convention rather than only the image dimensions.

Include the projection model

The sensor reference distinguishes perspective and orthographic sensors and documents clipping controls. A conversion derived for a pinhole should not silently govern every camera plugin. Preserve projection parameters and camera-to-world transforms with each sample. Check objects near image corners, since they expose radial-versus-axial differences more clearly than a small object centered in the frame. Resolve clipping and missing intersections before applying a numerical normalization.

Treat boundaries as mixed measurements

The reconstruction filter documentation explains how samples become pixels. Across an object boundary, a filtered depth value may combine observations of different surfaces. An RGB edge that looks smooth does not establish a unique geometric label there. Define whether the task accepts integrated measurements, center-ray labels or a conservative validity mask. Preserve that choice when comparing generated supervision with a real depth sensor.

Use a planar diagnostic scene

Render a front-facing plane spanning the frame and inspect center and corner pixels under the chosen convention. A constant axial plane should not be mistaken for a constant radial range image. The guides to renderer compatibility and image coordinate transforms address neighboring assumptions. Accept the export only after camera geometry, distance units, invalid pixels and reconstruction behavior explain the actual label tensor.

Earn rental income from GPUs

Have idle GPUs or looking to fund AI infrastructure? Retrivium finds a rental platform, sets up the server and helps you assess income and costs with a pilot.

Explore GPU hosting
← All articles