Shape-model fitting recovers 3D femur from two X-ray silhouettes

Research Coding

TL;DR: A no-CT, no-neural-network pipeline fits a PCA shape model to two X-ray silhouettes via PyTorch3D differentiable rendering, achieving sub-1.5mm accuracy on held-out femurs.

Summary: A developer built a pipeline that reconstructs patient-specific 3D distal femur geometry from only PA and lateral X-ray silhouettes, using a statistical shape model built from 50 CT-derived femur meshes (MedShapeNet). The model is fit with PyTorch3D's soft rasterizer, sigma annealing, a Mahalanobis prior, and Adam optimization, with correspondence handled via ShapeWorks. Leave-one-out validation on five held-out femurs showed 0.86–1.43mm accuracy for shapes inside the model's coverage, while extreme outlier shapes exposed the limits of the PCA basis.

Why it matters: It demonstrates a viable alternative to heavy neural networks for sparse-view 3D reconstruction, using differentiable rendering plus a shape prior. Watch for applications in surgical planning and musculoskeletal analysis, and try similar SSM-plus-rendering pipelines for other anatomical or industrial shapes.

Source: reddit