## Goal
`scene.json` gives two ordered lists of 3D points, `src` and `dst` (same length,
point `src[i]` corresponds to `dst[i]`), related by an unknown **similarity
transform** plus small measurement noise:

```
dst[i] ≈ s · R · src[i] + t
```

Recover the scalar scale `s > 0`, the rotation `R` (3×3, orthonormal, det +1), and the
translation `t` (3-vector, mm) that minimize the mean squared residual. Write them to
`result.json` along with the achieved RMS error.

## Method (accepted: any correct least-squares solution)
Closed form (Umeyama 1991):
1. Centroids `μ_s`, `μ_d`; centered `X_s = src − μ_s`, `X_d = dst − μ_d`.
2. `Σ = (1/N) X_dᵀ X_s`; SVD `Σ = U D Vᵀ`.
3. `S = I`, but set `S[2,2] = −1` if `det(U)·det(V) < 0`. Then `R = U S Vᵀ`.
4. `s = trace(D S) / var(src)` where `var(src) = (1/N) Σ‖X_s‖²`.
5. `t = μ_d − s R μ_s`.

## Input: `scene.json`
```
{ "src": [[x,y,z], ...], "dst": [[x,y,z], ...] }
```

## Output: `result.json`
```
{
  "scale": <float>,
  "R": [[3x3]],
  "t": [x, y, z],
  "rms_error": <float>   // sqrt( mean_i || s R src_i + t - dst_i ||^2 )
}
```
`R` must be a valid rotation (orthonormal, det +1). Python 3.11 + NumPy only. No
network access.
