{
  "cases": [
    {
      "caseId": "GLN-12-NEUTRAL-STAND",
      "labelEn": "Neutral Standing Long-Leg & Spinopelvic Alignment (0 deg Rotation)",
      "labelKo": "중립 기립 전장 하지·척추골반 정렬 (회전 0°, 표준 기준 영상)",
      "metrics": {
        "absErrorDeg": 0.022,
        "naive2dHkaDeg": -2.08,
        "piMinusPtPlusSsDeg": 0.0,
        "rayCastMeasuredHkaDeg": -1.98,
        "trueHkaDeg": -2.0
      },
      "verdict": "PASS",
      "viz": {
        "kind": "drr_xray",
        "landmarks2d": {
          "ankleCenter": [
            106.84,
            -87.1
          ],
          "femoralHead": [
            106.84,
            876.77
          ],
          "kneeCenter": [
            115.25,
            394.84
          ],
          "l1Sup": [
            0.0,
            1195.27
          ],
          "s1Plate": [
            0.0,
            967.51
          ]
        },
        "measuredHkaDeg": -1.98,
        "pelvicIncidenceDeg": 47.6,
        "pelvicTiltDeg": 11.2,
        "poseCurve": [
          {
            "naive2dErrDeg": 2.259,
            "rayCastCorrectedErrDeg": 0.045,
            "rotDeg": -15.0
          },
          {
            "naive2dErrDeg": 1.625,
            "rayCastCorrectedErrDeg": 0.047,
            "rotDeg": -12.0
          },
          {
            "naive2dErrDeg": 1.011,
            "rayCastCorrectedErrDeg": 0.037,
            "rotDeg": -9.0
          },
          {
            "naive2dErrDeg": 0.39,
            "rayCastCorrectedErrDeg": 0.018,
            "rotDeg": -6.0
          },
          {
            "naive2dErrDeg": 0.198,
            "rayCastCorrectedErrDeg": 0.009,
            "rotDeg": -3.0
          },
          {
            "naive2dErrDeg": 0.797,
            "rayCastCorrectedErrDeg": 0.037,
            "rotDeg": 0.0
          },
          {
            "naive2dErrDeg": 1.349,
            "rayCastCorrectedErrDeg": 0.064,
            "rotDeg": 3.0
          },
          {
            "naive2dErrDeg": 1.921,
            "rayCastCorrectedErrDeg": 0.083,
            "rotDeg": 6.0
          },
          {
            "naive2dErrDeg": 2.422,
            "rayCastCorrectedErrDeg": 0.092,
            "rotDeg": 9.0
          },
          {
            "naive2dErrDeg": 2.949,
            "rayCastCorrectedErrDeg": 0.086,
            "rotDeg": 12.0
          },
          {
            "naive2dErrDeg": 3.41,
            "rayCastCorrectedErrDeg": 0.064,
            "rotDeg": 15.0
          }
        ],
        "rotationDeg": 0.0,
        "sacralSlopeDeg": 36.4,
        "trueHkaDeg": -2.0
      }
    },
    {
      "caseId": "GLN-12-EXTROT10-FLEX10",
      "labelEn": "+10 deg External Rotation + 10 deg Knee Flexion (Parallax Rescued)",
      "labelKo": "외회전 +10° 및 슬관절 굴곡 10° 동반 변형 (단순 2D 시차오차 보정)",
      "metrics": {
        "naive2dErrorDeg": 2.6,
        "naive2dHkaDeg": -7.6,
        "rayCastErrorDeg": 0.09,
        "rayCastMeasuredHkaDeg": -4.91,
        "trueHkaDeg": -5.0
      },
      "verdict": "PASS",
      "viz": {
        "kind": "drr_xray",
        "landmarks2d": {
          "ankleCenter": [
            106.84,
            -87.1
          ],
          "femoralHead": [
            106.84,
            876.77
          ],
          "kneeCenter": [
            137.74,
            389.86
          ],
          "l1Sup": [
            0.0,
            1197.3
          ],
          "s1Plate": [
            0.0,
            968.67
          ]
        },
        "measuredHkaDeg": -4.91,
        "pelvicIncidenceDeg": 53.4,
        "pelvicTiltDeg": 14.8,
        "poseCurve": [
          {
            "naive2dErrDeg": 2.259,
            "rayCastCorrectedErrDeg": 0.045,
            "rotDeg": -15.0
          },
          {
            "naive2dErrDeg": 1.625,
            "rayCastCorrectedErrDeg": 0.047,
            "rotDeg": -12.0
          },
          {
            "naive2dErrDeg": 1.011,
            "rayCastCorrectedErrDeg": 0.037,
            "rotDeg": -9.0
          },
          {
            "naive2dErrDeg": 0.39,
            "rayCastCorrectedErrDeg": 0.018,
            "rotDeg": -6.0
          },
          {
            "naive2dErrDeg": 0.198,
            "rayCastCorrectedErrDeg": 0.009,
            "rotDeg": -3.0
          },
          {
            "naive2dErrDeg": 0.797,
            "rayCastCorrectedErrDeg": 0.037,
            "rotDeg": 0.0
          },
          {
            "naive2dErrDeg": 1.349,
            "rayCastCorrectedErrDeg": 0.064,
            "rotDeg": 3.0
          },
          {
            "naive2dErrDeg": 1.921,
            "rayCastCorrectedErrDeg": 0.083,
            "rotDeg": 6.0
          },
          {
            "naive2dErrDeg": 2.422,
            "rayCastCorrectedErrDeg": 0.092,
            "rotDeg": 9.0
          },
          {
            "naive2dErrDeg": 2.949,
            "rayCastCorrectedErrDeg": 0.086,
            "rotDeg": 12.0
          },
          {
            "naive2dErrDeg": 3.41,
            "rayCastCorrectedErrDeg": 0.064,
            "rotDeg": 15.0
          }
        ],
        "rotationDeg": 10.0,
        "sacralSlopeDeg": 38.6,
        "trueHkaDeg": -5.0
      }
    },
    {
      "caseId": "GLN-12-SPONDYLO-SL",
      "labelEn": "High-Grade Spondylolisthesis Spinopelvic Retroversion Imbalance",
      "labelKo": "척추전방전위증(SL) 고경사 골반 후방경사 보상 불균형 증례",
      "metrics": {
        "lumbarLordosisDeg": 82.68,
        "pelvicIncidenceDeg": 85.68,
        "pelvicTiltDeg": 38.65,
        "piPtSsResidualDeg": 0.0,
        "sacralSlopeDeg": 47.03
      },
      "verdict": "PASS",
      "viz": {
        "kind": "drr_xray",
        "landmarks2d": {
          "ankleCenter": [
            106.84,
            -87.1
          ],
          "femoralHead": [
            106.84,
            876.77
          ],
          "kneeCenter": [
            121.28,
            393.22
          ],
          "l1Sup": [
            0.0,
            1209.25
          ],
          "s1Plate": [
            0.0,
            975.81
          ]
        },
        "measuredHkaDeg": -2.96,
        "pelvicIncidenceDeg": 85.68,
        "pelvicTiltDeg": 38.65,
        "poseCurve": [
          {
            "naive2dErrDeg": 2.259,
            "rayCastCorrectedErrDeg": 0.045,
            "rotDeg": -15.0
          },
          {
            "naive2dErrDeg": 1.625,
            "rayCastCorrectedErrDeg": 0.047,
            "rotDeg": -12.0
          },
          {
            "naive2dErrDeg": 1.011,
            "rayCastCorrectedErrDeg": 0.037,
            "rotDeg": -9.0
          },
          {
            "naive2dErrDeg": 0.39,
            "rayCastCorrectedErrDeg": 0.018,
            "rotDeg": -6.0
          },
          {
            "naive2dErrDeg": 0.198,
            "rayCastCorrectedErrDeg": 0.009,
            "rotDeg": -3.0
          },
          {
            "naive2dErrDeg": 0.797,
            "rayCastCorrectedErrDeg": 0.037,
            "rotDeg": 0.0
          },
          {
            "naive2dErrDeg": 1.349,
            "rayCastCorrectedErrDeg": 0.064,
            "rotDeg": 3.0
          },
          {
            "naive2dErrDeg": 1.921,
            "rayCastCorrectedErrDeg": 0.083,
            "rotDeg": 6.0
          },
          {
            "naive2dErrDeg": 2.422,
            "rayCastCorrectedErrDeg": 0.092,
            "rotDeg": 9.0
          },
          {
            "naive2dErrDeg": 2.949,
            "rayCastCorrectedErrDeg": 0.086,
            "rotDeg": 12.0
          },
          {
            "naive2dErrDeg": 3.41,
            "rayCastCorrectedErrDeg": 0.064,
            "rotDeg": 15.0
          }
        ],
        "rotationDeg": 2.5,
        "sacralSlopeDeg": 47.03,
        "trueHkaDeg": -3.0
      }
    },
    {
      "caseId": "GLN-12-MALROT14-HOLD",
      "labelEn": "+14.5 deg Severe Limb Malrotation (>12 deg Patellar Off-Center -> QC HOLD)",
      "labelKo": "+14.5° 중증 하지 회전 촬영오류 (>12° 슬개골 편위 자동 재촬영 보류 HOLD)",
      "metrics": {
        "estimatedRotationDeg": 14.444,
        "holdReason": "SEVERE_LIMB_MALROTATION_RETAKE_REQUIRED",
        "qcThresholdDeg": 12.0,
        "uncorrectedNaive2dErrDeg": 3.97
      },
      "verdict": "HOLD",
      "viz": {
        "kind": "drr_xray",
        "landmarks2d": {
          "ankleCenter": [
            106.84,
            -87.1
          ],
          "femoralHead": [
            106.84,
            876.77
          ],
          "kneeCenter": [
            145.33,
            388.58
          ],
          "l1Sup": [
            0.0,
            1196.73
          ],
          "s1Plate": [
            0.0,
            968.42
          ]
        },
        "measuredHkaDeg": -9.47,
        "pelvicIncidenceDeg": 51.0,
        "pelvicTiltDeg": 14.0,
        "poseCurve": [
          {
            "naive2dErrDeg": 2.259,
            "rayCastCorrectedErrDeg": 0.045,
            "rotDeg": -15.0
          },
          {
            "naive2dErrDeg": 1.625,
            "rayCastCorrectedErrDeg": 0.047,
            "rotDeg": -12.0
          },
          {
            "naive2dErrDeg": 1.011,
            "rayCastCorrectedErrDeg": 0.037,
            "rotDeg": -9.0
          },
          {
            "naive2dErrDeg": 0.39,
            "rayCastCorrectedErrDeg": 0.018,
            "rotDeg": -6.0
          },
          {
            "naive2dErrDeg": 0.198,
            "rayCastCorrectedErrDeg": 0.009,
            "rotDeg": -3.0
          },
          {
            "naive2dErrDeg": 0.797,
            "rayCastCorrectedErrDeg": 0.037,
            "rotDeg": 0.0
          },
          {
            "naive2dErrDeg": 1.349,
            "rayCastCorrectedErrDeg": 0.064,
            "rotDeg": 3.0
          },
          {
            "naive2dErrDeg": 1.921,
            "rayCastCorrectedErrDeg": 0.083,
            "rotDeg": 6.0
          },
          {
            "naive2dErrDeg": 2.422,
            "rayCastCorrectedErrDeg": 0.092,
            "rotDeg": 9.0
          },
          {
            "naive2dErrDeg": 2.949,
            "rayCastCorrectedErrDeg": 0.086,
            "rotDeg": 12.0
          },
          {
            "naive2dErrDeg": 3.41,
            "rayCastCorrectedErrDeg": 0.064,
            "rotDeg": 15.0
          }
        ],
        "rotationDeg": 14.5,
        "sacralSlopeDeg": 37.0,
        "trueHkaDeg": -5.5
      }
    }
  ],
  "findings": [
    {
      "detailEn": "Cone-beam Beer-Lambert ray-casting at SID=1800 mm proves naive 2D coronal landmarking incurs 2.86 deg MAE under combined flexion + rotation (exceeding the +/-3 deg surgical safe zone for TKA/HTO). While 3D patellar-epicondylar ray-cast inversion reduces MAE to 0.045 deg up to 12 deg rotation, severe malrotation (>12 deg) suffers condylar silhouette overlap and is automatically held for radiographic retake.",
      "detailKo": "SID 1800 mm 원추빔 Beer-Lambert 모사 결과, 굴곡·회전이 동반된 환자에서 단순 2D 계측은 평균 2.86°의 심각한 시차 오차를 유발합니다. 3D 슬개-상과 변위 역산 보정으로 ±12° 이내에서 MAE를 0.045°까지 억제하나, 12° 초과 중증 회전에서는 과간 중첩으로 인해 재촬영 보류(HOLD)가 필수입니다.",
      "id": "XRAY12-F1-FLEXION-ROTATION-PARALLAX",
      "severity": "HOLD",
      "status": "HOLD",
      "titleEn": "Combined Knee Flexion (>=9 deg) + Limb Rotation (>=9 deg) Induces >2.5 deg Naive 2D HKA Parallax",
      "titleKo": "슬관절 굴곡(>=9°) 및 하지 내·외회전(>=9°) 동반 시 단순 2D 계측 2.5° 초과 시차 왜곡 발생"
    },
    {
      "detailEn": "Angular metrics (HKA, PI, PT, SS, Cobb) are scale-invariant up to perspective depth, whereas millimeter translation (spondylolisthesis slip mm, osteotomy wedge mm) incurs ~11-16% cone-beam magnification bias unless a 25 mm radiopaque calibration sphere or verified ImagerPixelSpacing is present.",
      "detailKo": "정렬각(HKA, PI, PT, SS)과 달리 전방전위 밀리미터(mm) 이동량 및 절골 쐐기 높이는 검출기 배율(11~16%) 영향을 받으므로 25 mm 금속 보정구 또는 검증된 DICOM 픽셀간격 태그 없이는 선형 출력을 잠금(HOLD) 처리해야 합니다.",
      "id": "XRAY12-F2-DICOM-CALIBRATION-MARKER-DEPENDENCY",
      "severity": "HOLD",
      "status": "HOLD",
      "titleEn": "Linear Millimeter Slip & Magnification Require Calibrated Fiducial Ball or DICOM (0028,0030)",
      "titleKo": "선형 거리(mm) 전방전위 계측 시 방사선 배율 마커(Fiducial Sphere) 및 DICOM 태그 필수"
    },
    {
      "detailEn": "Clinical licensure requires MFDS Radiological Mensuration SaMD validation across multi-vendor stitched CR/DR long-cassette detectors and two-radiologist Bland-Altman 95% limits-of-agreement IRB study.",
      "detailKo": "상용 의료기기 허가를 위해서는 다기종 전장(Long-Cassette) 디지털 엑스선 스티칭 검출기 팬텀 시험 및 영상의학과·정형외과 전문의 간 Bland-Altman 일치도 한계(LoA) 임상시험(IRB)이 요구됩니다.",
      "id": "XRAY12-F3-MFDS-BLAND-ALTMAN-STATUTORY-GATE",
      "severity": "EXT",
      "status": "EXT",
      "titleEn": "Statutory Gate: MFDS Orthopedic Mensuration SaMD Review & Multi-Vendor Detector Bland-Altman Trial",
      "titleKo": "법정 외부 게이트: 식약처 정형외과 계측 SaMD 심사 및 다기종 DR 검출기·전문의 Bland-Altman 실증"
    }
  ],
  "gates": {
    "G1": {
      "detailEn": "Verified vertebral_column.zip SHA-256 digest across 310 orthopedic patients with strict 186-train / 124-test zero-overlap partition and pseudonymized subject IDs.",
      "detailKo": "vertebral_column.zip(310명) SHA-256 해시 일치, 학습 186명 / 잠금 테스트 124명 환자 비중복 분할 및 가명화 식별자 무결성을 검증했습니다.",
      "observed": {
        "errors": [],
        "lockedTestPatients": 124,
        "totalPatients": 310,
        "virtualDrrs": 180
      },
      "status": "PASS",
      "titleEn": "UCI 310-Patient SHA-256 Provenance & Zero-Overlap Stratified Split",
      "titleKo": "UCI 정형외과 310명 코호트 SHA-256 무결성 및 환자 비중복 층화분할 검증"
    },
    "G2": {
      "detailEn": "Independently verified max |PI - (PT + SS)| = 0.0100 deg across all 310 real patients and max Beer-Lambert |I - exp(-tau)| residual = 5.17e-07 across 180 DRRs.",
      "detailKo": "실제 환자 310명 전수에서 |PI - (PT + SS)| 최대 잔차 0.0100° 및 가상 DRR 180장 Beer-Lambert 지수 감쇠 잔차 5.17e-07를 독립 확인했습니다.",
      "observed": {
        "errors": [],
        "maxBeerLambertResidual": 5.2e-07,
        "maxSpinopelvicResidualDeg": 0.01
      },
      "status": "PASS",
      "titleEn": "Spinopelvic Conservation (PI = PT + SS) & Beer-Lambert Ray Law",
      "titleKo": "척추골반 기하 보존법칙(PI = PT + SS) 및 Beer-Lambert 감쇠 법칙 검증"
    },
    "G3": {
      "detailEn": "Recomputed UCI locked-test AUROC=0.9027 (vs single-angle=0.7374) and 3D ray-cast HKA MAE=0.045 deg (< 0.45 deg) vs flexion+rotation naive 2D=2.86 deg.",
      "detailKo": "UCI 홀드아웃 시상면 병변 AUROC 0.9027(단일 각도 베이스라인 0.7374) 및 3D 광선투사 보정 HKA 절대오차 0.045°(굴곡·회전 동반 단순 2D 오차 2.86°)를 독립 재검산했습니다.",
      "observed": {
        "errors": [],
        "recomputedRayCastHkaMaeDeg": 0.0453,
        "recomputedSevereNaive2dMaeDeg": 2.8592,
        "recomputedUciAuroc": 0.902679
      },
      "status": "PASS",
      "titleEn": "Solver-Free Sagittal AUROC & 3D Ray-Cast HKA Mensuration Recomputation",
      "titleKo": "솔버 독립 시상면 병변 AUROC 및 3D 광선투사 HKA 정렬각 오차 재검산"
    },
    "G4": {
      "detailEn": "Triggers automatic retake HOLD on 42/180 severely malrotated DRRs (|rot| > 12 deg, 100.0% recall on >=13 deg) to prevent osteotomy planning errors.",
      "detailKo": "슬개골 편위가 12°를 초과하는 중증 회전 오류 영상(42/180장)에서 자동 재촬영 보류(HOLD)를 발동하여 절골술(HTO)·인공관절 각도 계측 오진을 원천 차단합니다.",
      "observed": {
        "errors": [],
        "interactiveHoldCases": 1,
        "malrotationHoldRecallPct": 100.0,
        "qcHeldDrrs": 42
      },
      "status": "PASS",
      "titleEn": "Extreme Limb Malrotation (>12 deg) Automatic QC HOLD & MFDS CADm Gate",
      "titleKo": "하지 중증 회전오류(>12°) 자동 품질보류(HOLD) 및 식약처 계측 SaMD 법정 경계"
    }
  },
  "humanAuditorSignature": null,
  "inputProvenance": [
    {
      "label": "vertebral_column.zip",
      "records": 310,
      "sha256": "899ed1d137ceb4c36d59fa35f3cbab39ec3b78fd3ca1fdaf2fae155459c1372f"
    }
  ],
  "narrative": {
    "headlineEn": "3D Cone-Beam Beer-Lambert ray-cast correction cuts pose-perturbed HKA alignment MAE to 0.045 deg (vs 2.86 deg naive 2D parallax under flexion+rotation) with 100% QC HOLD on severe malrotation, while reaching 0.9027 locked-test AUROC (vs 0.7374 single-angle baseline) across the 310-patient UCI orthopedic cohort.",
    "headlineKo": "3차원 원추빔 Beer-Lambert 광선투사 자세보정으로 하지 회전·굴곡 섭동 HKA 계측 오차를 0.045°로 억제하고(굴곡·회전 동반 단순 2D 오차 2.86° 대비 대폭 개선, 중증 회전 자동 HOLD), UCI 정형외과 310명 실측 코호트 잠금 검증에서 시상면 병변 AUROC 0.9027(단일 각도 0.7374)를 달성했습니다.",
    "methodEn": "Models SID=1800 mm cone-beam perspective projection and analytical Beer-Lambert chord attenuation I(u,v) = I0*exp(-sum mu_k*L_k) over a 3D lower-limb/spinopelvic phantom, paired with PI = PT + SS geometric conservation verification and Schwab PI-LL / Vialle pelvic retroversion biomechanical scoring.",
    "methodKo": "SID 1800 mm 원추빔 투영 및 Beer-Lambert 골피질·해면골 선적분 감쇠 모사로 슬개-상과 편위를 역산해 3차원 시차 왜곡을 제거하고, 실제 310명 코호트의 PI = PT + SS 기하 보존 검증 및 Schwab·Vialle 척추골반 생체역학 지표 결합 모델을 솔버 독립 감사했습니다."
  },
  "overallStatus": "PASS",
  "package": "xray11_12",
  "primaryMetric": {
    "baselineNameEn": "Single-Angle Radiographic Mensuration Baseline (Pelvic Incidence Only)",
    "baselineNameKo": "단일 방사선 각도 계측 베이스라인 (골반입사각 PI 단독)",
    "baselineValue": 0.737351,
    "ci95": [
      0.84881,
      0.947321
    ],
    "denominator": 124,
    "nameEn": "Locked-Test Spinopelvic Sagittal Pathology (DH/SL vs Normal) AUROC",
    "nameKo": "홀드아웃 척추·골반 시상면 정렬 이상(추간판탈출·전방전위 대 정상) 판별 AUROC",
    "targetSpec": "Locked-Test AUROC >= 0.88 & 3D Ray-Cast Corrected HKA MAE < 0.45 deg",
    "unit": "AUROC",
    "value": 0.902679
  },
  "rfpCode": "11-1 [1-2]",
  "runSha256": "ab8c9dee5636000590f4cb8da8caa5cf56d41e5466592e8ef130fcfb84309a96",
  "schemaVersion": 1,
  "secondaryMetrics": [
    {
      "ci95": null,
      "id": "raycast_corrected_hka_mae_deg",
      "nameEn": "3D Beer-Lambert Ray-Cast Corrected HKA Alignment MAE (|rot| <= 12 deg)",
      "nameKo": "3D Beer-Lambert 광선투사 자세보정 HKA 정렬각 절대오차 MAE (|회전| <= 12°)",
      "unit": "deg",
      "value": 0.0453
    },
    {
      "ci95": null,
      "id": "severe_flex_rot_naive2d_mae_deg",
      "nameEn": "Parallax Ablation: Naive 2D HKA Error Under Flexion (>=9 deg) + Rotation (>=9 deg)",
      "nameKo": "시차 왜곡 비교군: 굴곡(>=9°)·회전(>=9°) 동반 시 단순 2D 계측 HKA 오차",
      "unit": "deg",
      "value": 2.8592
    },
    {
      "ci95": null,
      "id": "naive_2d_all_pose_mae_deg",
      "nameEn": "Overall Naive 2D Radiographic HKA MAE Across All 180 Pose Perturbations",
      "nameKo": "전체 180장 자세 섭동 가상 엑스선에서의 단순 2D 계측 평균 오차",
      "unit": "deg",
      "value": 1.2295
    },
    {
      "ci95": null,
      "id": "spinopelvic_pi_pt_ss_max_residual_deg",
      "nameEn": "Real UCI 310-Patient Spinopelvic Conservation Max Residual |PI - (PT + SS)|",
      "nameKo": "실제 UCI 310명 척추골반 보존항등식 |PI - (PT + SS)| 최대 잔차",
      "unit": "deg",
      "value": 0.01
    },
    {
      "ci95": null,
      "id": "malrotation_qc_hold_recall_pct",
      "nameEn": "Extreme Malrotation (>=13 deg) Automatic Quality-Control HOLD Recall",
      "nameKo": "중증 촬영 회전오류(>=13°) 자동 품질보류(QC HOLD) 포착률",
      "unit": "%",
      "value": 100.0
    }
  ],
  "solverFreeAst": {
    "file": "audit.py",
    "importedModules": [
      "__future__",
      "audit_lib.independent_metrics",
      "audit_lib.track_contract",
      "json",
      "math",
      "pathlib",
      "typing",
      "zipfile"
    ],
    "solverFree": true,
    "violations": []
  }
}
