{
  "original": {
    "width": 1600,
    "height": 1200,
    "megapixels": 1.92
  },
  "staged": {
    "width": 2048,
    "height": 1536,
    "megapixels": 3.15
  },
  "aspect_ratio": {
    "original": 1.3333,
    "staged": 1.3333,
    "deviation": 0.0,
    "pass": true
  },
  "resolution_kept": true,
  "resolution_ratio": 1.638,
  "raw_drift_score": 54.1,
  "alignment": {
    "ok": true,
    "method": "SIFT + ratio test + RANSAC similarity (estimateAffinePartial2D)",
    "keypoints_original": 736,
    "keypoints_staged": 1640,
    "matches": 143,
    "affine_anisotropy": 0.0043,
    "inliers": 56,
    "inlier_ratio": 0.392,
    "median_residual_px": 1.22,
    "matrix_staged_to_original_work": [
      [
        1.00992,
        -0.00477,
        -6.75474
      ],
      [
        0.00477,
        1.00992,
        179.50754
      ]
    ]
  },
  "framing": {
    "pass": false,
    "result": "fail: only 76.3% of the original frame visible; 24.9% of the output is outside the original frame",
    "zoom": 0.9902,
    "shift_px": [
      -5.5,
      290.2
    ],
    "shift_pct": [
      -0.34,
      24.19
    ],
    "rotation_deg": 0.27,
    "visible_overlap_pct": 76.3,
    "invented_area_pct": 24.92,
    "original_px_lost": {
      "left": 0.0,
      "right": 0.4,
      "top": 288.1,
      "bottom": 0.0
    },
    "criteria": "overlap >= 97%, zoom 0.99-1.02, |rotation| <= 0.5 deg, invented area <= 2%",
    "units": "px of the original image; shift = staged frame centre vs original centre; zoom > 1 = cropped/zoomed in"
  },
  "diagnostics": {
    "sensitive_edges": {
      "line_recall": 0.9082,
      "line_displaced_frac": 0.0867,
      "line_missing_frac": 0.0051,
      "structural_line_pixels": 36206
    },
    "note": "low-threshold Canny that also sees white wall/soffit/column edges; not part of drift_score"
  },
  "architecture": {
    "edge_ssim": 0.7226,
    "line_recall": 0.8067,
    "line_displaced_frac": 0.15,
    "line_missing_frac": 0.0433,
    "structural_line_pixels": 14950,
    "evaluated_area_frac": 0.408,
    "drift_score": 23.5,
    "aligned": true,
    "evaluated_area_frac_of_mask": 0.627,
    "mask": "auto: top 65% of frame"
  },
  "drift_score": 23.5,
  "structure": {
    "edge_ssim": 0.471,
    "line_recall": 0.448,
    "line_displaced_frac": 0.277,
    "line_missing_frac": 0.275,
    "structural_line_pixels": 22037,
    "evaluated_area_frac": 0.65,
    "drift_score": 54.1,
    "mask": "auto: top 65% of frame",
    "note": "legacy unaligned structure check (= raw_drift_score)"
  },
  "seconds_to_result": 45,
  "seconds_approx": true,
  "files": {
    "original": "photos/08-loft-kitchen-ducts.jpg",
    "staged": "results/pedra/08.jpg"
  }
}