﻿# Normal supervision in Mitsuba: separate surface geometry, shading and coordinate frames

Choose geometric or shading normal labels in Mitsuba and preserve coordinate transforms, signed components and edge validity throughout a synthetic training pipeline.

Author: Retrivium editorial team
Updated: 2026-11-04
Canonical URL: https://retrivium.ai/journal/fg2-mitsuba-normal-aov-frame-label-target/
Language: en

## Decide what the network predicts

A surface-normal model needs an explicit target. A geometric normal describes the surface orientation derived from geometry, while a shading normal can incorporate interpolated vertex normals or appearance detail. Either may be useful, but substituting one for the other changes the learning problem. State whether the task reconstructs shape, predicts the renderer's shading frame or supplies a feature to another image operation before selecting an output.

## Select the corresponding AOV

The [Mitsuba integrator reference](https://mitsuba.readthedocs.io/en/latest/src/generated/plugins_integrators.html) exposes separate `geo_normal` and `sh_normal` outputs. Save their identities in channel metadata rather than calling both simply normal. A smooth-looking low-polygon object is a useful diagnostic: the shading field can look continuous while geometric orientation changes across faces. More samples cannot reconcile these different definitions, because the disagreement is part of the scene representation rather than sampling noise.

## Establish the coordinate transformation

The [transformation toolbox](https://mitsuba.readthedocs.io/en/latest/src/how_to_guides/transformation_toolbox.html) distinguishes frames and typed transformations. Identify the frame returned by the chosen API in your installed release, then transform into the model's declared frame. Normals under a nonuniform geometric transform require the appropriate inverse-transpose treatment; camera-frame conversion also depends on the camera orientation. Use the [sensor conventions](https://mitsuba.readthedocs.io/en/latest/src/generated/plugins_sensors.html) to check handedness and forward direction rather than assuming a familiar graphics convention.

## Preserve numerical meaning during export

A false-color normal preview often remaps signed components for display. Keep that visualization mapping outside the training target unless the model explicitly expects it. Filtering across silhouettes can shorten vectors or mix foreground with background. Define a validity mask and decide whether normalization is meaningful after reconstruction. Renormalizing a mixture does not recover the normal of either original surface, so boundary handling should be part of the annotation contract.

## Check rotations and sharp features

Render an asymmetric object with both sharp and smooth regions, rotate the camera, and inspect the exported vectors numerically. Geometry should explain the changes under the declared frame. The guides to [denoiser feature buffers](/journal/learn-denoiser-feature-buffers/) and [image coordinate integrity](/journal/data-guide-image-exif-box-coordinate/) offer adjacent context. Accept the labels only when normal type, frame, signed representation and boundary behavior remain consistent after loading them through the training input pipeline.
