Maintenance of the Mayo clinic human CT dataset loader#1589
Maintenance of the Mayo clinic human CT dataset loader#1589pierocor wants to merge 4 commits intoodlgroup:masterfrom
Conversation
kohr-h
left a comment
There was a problem hiding this comment.
Thanks a lot for going though the trouble to keep the Mayo dataset working! Please have a look at my review comments. They should be rather straightforward to address.
Regarding functionality, I trust that the changes you made work for you, so they're kind of tested. After all, it's in contrib.
| # define data folders | ||
| proj_folder = odl.__path__[0] + '/../../data/LDCT-and-Projection-data/' \ | ||
| 'L004/08-21-2018-10971/1.000000-Full dose projections-24362/' | ||
| rec_folder = odl.__path__[0] + '/../../data/LDCT-and-Projection-data/' \ | ||
| 'L004/08-21-2018-84608/1.000000-Full dose images-59704/' |
There was a problem hiding this comment.
- I suggest to use
odl.contrib.datasets.util.get_data_dir()to determine a storage location. - What are the reasons to change the dataset directory? It would be good to have a small comment on top that says which data it is.
- Please use
dirinstead offolder. The latter is Windows lingo, and Python uses e.g.is_dir()to check if aPathobject represents a directory.
There was a problem hiding this comment.
The Mayo dataset cannot be downloaded directly from a url but it requires its own software. This prevents to use odl.contrib.datasets.util.get_data(filename, subset, url) for local caching. Would this work better?
| # define data folders | |
| proj_folder = odl.__path__[0] + '/../../data/LDCT-and-Projection-data/' \ | |
| 'L004/08-21-2018-10971/1.000000-Full dose projections-24362/' | |
| rec_folder = odl.__path__[0] + '/../../data/LDCT-and-Projection-data/' \ | |
| 'L004/08-21-2018-84608/1.000000-Full dose images-59704/' | |
| # replace with your local directory | |
| mayo_dir = '' | |
| # define projection and reconstruction data directories | |
| # e.g. for patient L004 full dose CT scan: | |
| proj_dir = os.path.join( | |
| mayo_dir, 'L004/08-21-2018-10971/1.000000-Full dose projections-24362/') | |
| rec_dir = os.path.join( | |
| mayo_dir, 'L004/08-21-2018-84608/1.000000-Full dose images-59704/') |
| geometry, proj_data = mayo.load_projections(proj_folder, | ||
| indices=slice(16000, 19000)) |
There was a problem hiding this comment.
Same question as above: why change the slice?
There was a problem hiding this comment.
It has been adjusted to the example considered (patient L004). In this case, the projection data counts ~32k images and the above slice choice reconstructs a central part of the volume.
5765d0a to
96a7d5e
Compare
This branch updates the loader and utility code for the Mayo clinic human CT dataset. In particular:
src_shift_funcof theConeBeamGeometry.