rg2 / xreg

Library and executables for modeling and registration applications in medical image analysis. Particular emphasis on intraoperative fluoroscopic (X-ray) navigation via 2D/3D registration.
MIT License
91 stars 18 forks source link

why xreg has so many errors #20

Closed victorswan closed 7 months ago

victorswan commented 2 years ago

I try this 2d/3d registration example: https://github.com/rg2/xreg/wiki/Example%3A-TCIA-Hip-Radiograph-Rigid-Registration all the data I downloaded from all the links on the page. after data is ready I began to run the program xreg-ipcai-intraop-pelvis-femurs-regi.exe. At once I got error. then I try to debug it. firstly at RunPelvisAndFemursIntraopRegi() function in IPCAICommon.cpp, when running into this: const bool pat_is_up = pd.rot_to_pat_up == ProjDataRotToPatUp::kZERO; it report error, then I remove the and modified it as: const bool pat_is_up = pd.rot_to_pat_up == ProjDataRotToPatUp::kZERO; the error disappeared. but when I running into void xreg::MultiLevelMultiObjRegi::run() function of xregMultiObjMultiLevel2D3DRegi.cpp another error appeared at: auto& cur_mask_to_ds = masks_2d[global_fixed_idx]; the reason is masks_2d is empty. but before this there is a assert: const bool masks_provided = !masks_2d.empty(); xregASSERT(!masks_provided || (masks_2d.size() == num_fixed_imgs)); this assertion has not any usage because it would not report error only if one of two conditions is satisfied. since there is no error report on assertion. then "auto& cur_mask_to_ds = masks_2d[global_fixed_idx];" report error. it has no check for empty masks_2d. this made me confused. why xreg has so many errors. I dont know how to continue

rg2 commented 7 months ago

Not an actionable question, so closing.