The codes in this repository are used to quantify the 2D & 3D bone density of the proximal femur from CT images. 2D bone density of the neck region can also be measured.
- MATLAB
- Bilateral femur segmentation (Segmented by the model in Femur_segmentation)
- Calibration phantom segmentation (If BMD conversion is needed. Segmented by models in Phantom-segmentation)
For a sample of json file, please see sample_setup.json
- CT images (saved as .mhd)
- Segmented label (from U-net, saved as .mhd)
- Eight landmarks (from 3D slicer, saved as .fcsv)
- Head neck junction (superior, inferior, anterior, posterior)
Shaft (2cm distal from the lesser trochanter, 5cm distal from the lesser trochanter)- Head center
- Neck center
- Side of interest ('L' or 'R')
- Slope and intercept of the regression model (if BMD conversion is necessary. If conversion is not needed, put 0 for both parameters)
- Landmarks of the proximal femur selected by an AI trained model (https://github.com/NAIST-ICB/LandmarkDetection)
Two_dimensional_pipeline.m
- Required functions
- mhdread.m
- RegTools (can be downloaded from https://github.com/YoshitoOtake/RegTools)
- import_data.m
- isolate_bone_of_interest.m
- calculate_rotation_angles.m
- generate_proximal_femur_DRR.m
- select_DXA_region_DRR_label.m
- calculate_pixel_density.m
Two_dimensional_pipeline_neck.m
- Required functions
- mhdread.m
- RegTools (can be downloaded from https://github.com/YoshitoOtake/RegTools)
- import_data.m
- isolate_bone_of_interest.m
- calculate_rotation_angles.m
- generate_proximal_femur_DRR.m
- select_neck_region_DRR_label.m
- calculate_pixel_density.m
Three_dimensional_pipeline.m
- Required functions
- mhdread.m
- import_data.m
- isolate_bone_of_interest.m
- select_DXA_region_volume_label.m
- calculate_voxel_density.m
Codes can be used for research purpose or for educational purpose.
For details, please see LICENCE.txt