Closed surajpaib closed 4 months ago
Thanks for assessing MIRP's functionality.
I have created a task list so that I can keep track of the various things I need to look into:
xml
file.
Roxygen2
, but have not found a python equivalent. 👋 extract_mask_labels
.
pet_suv_conversion="none"
when DICOM PET units cannot be converted to SUV.Concerning some of the points:
The default argument for
image_export_format
seems to be adict
. Is there a reason this is preferred over thenative
type? As a user, I would expect the default behaviour to be native especially given that there is a concrete use-case for this type as seen in the tutorial. Are the users somehow expected to interact with thedict
type in their standard workflows?
Yes, extract_images
fulfils two main roles:
DataLoader
object.). The dict
export format provides easy access to the processed image and its sample name. dict
and not native
. I still recommend that people inspect their imaging, and hence included it in the tutorials.Certain PT modality files throw this error:
NotImplementedError: Conversion factor for converting PROPCPS to BQML is not implemented
MIRP tries to convert PET images to SUV by default, which requires a conversion from whatever PET units are present to BQML first. I will look into this particular case to see if there are metadata available to go from "proportional to counts per second" to BQML. Generally, I will try to make the error a bit more clear, because its only an issue when SUV conversion is required.
Additional stuff that might be useful:
extract_mask_labels
and extract_image_parameters
:
This may help stage specific images and masks for studies.
- From a data perspective, I wanted to point out that I'm unable to process (with
extract_images
func) certain DICOM objects available on the Imaging Data Commons which I am able to parse withpydicom_seg
. And then usingdicomsort
, I get several DICOM-SEG objects, one of them is attached to this issue. It gives me aValueError: negative dimensions are not allowed
error. It would also be useful if this error pointed out the exact file that causes it (when a dir is provided).
I was not able to reproduce the issue. I added a test, not only did the SEG file parse without issue, but the mask also exactly matches that of the RTSTRUCT original: https://github.com/oncoray/mirp/blob/834fce2900f9772764d6a1801b98eba04495864e/test/dicom_seg_test.py
Reopened for JOSS review.
Hi @alexzwanenburg. Thank you for updating the tutorial, this allows testing real world functionality much better.
While testing out various functionality mentioned in the docs and the software report, I've made the following observations.
I notice that several parameters have been provided as
kwargs
for the first tutorial. Especially in theextract_features
function call.It would be useful to link the tutorial section that mentions the overriding to the https://oncoray.github.io/mirp/configuration.html section so that the user has an idea of how and what parameters can be overridden.
Given the large number of parameters, it seems best to manage these with a configuration file which I see is provided via the means of an XML file. However, several entries don't correspond with their names in the python settings classes. Take the case of
vol_adapt
andImagePerturbationSettingsClass
that seem to map to each other. I recommend these be consistent for the best user experience.I see that a lot of parameters are dynamic keyword arguments. For instance,
image
parameter ofextract_features
. Because this is not defined explicitly in the function signature, I cannot find this in thehelp(extract_features)
check which would make it very difficult for the user to understand what is expected in these arguments.I also do not see this in https://oncoray.github.io/mirp/quantitative_image_analysis.html#mirp.extract_features_and_images.extract_features but I see that you have mentioned other keyword arguments here: https://oncoray.github.io/mirp/quantitative_image_analysis.html#mirp.extract_features_and_images.extract_features_and_images_generator. In this one the
import_image_and_mask()
hyperlink seems to be broken.I would make these dynamic keyword arguments very clear in each function call that uses them so as to avoid hidden/suprising behaviour for the end user.
The default argument for
image_export_format
seems to be adict
. Is there a reason this is preferred over thenative
type? As a user, I would expect the default behaviour to be native especially given that there is a concrete use-case for this type as seen in the tutorial. Are the users somehow expected to interact with thedict
type in their standard workflows?For the
extract_mask_labels
, I've tested this with different formats (DICOM-SEG & RTSTRUCT) and it looks great. One suggestion I would have is to also show themask_modality
in the table.From a data perspective, I wanted to point out that I'm unable to process (with
extract_images
func) certain DICOM objects available on the Imaging Data Commons which I am able to parse withpydicom_seg
.Using the code below,
And then using
dicomsort
, I get several DICOM-SEG objects, one of them is attached to this issue. It gives me aValueError: negative dimensions are not allowed
error. It would also be useful if this error pointed out the exact file that causes it (when a dir is provided).42_2d-tta_nnU-Net_Segmentation-1.dcm.zip
For the
nsclc_radiogenomics
cohort fetched as,when passing the
data
directory toextract_images
func, Certain PT modality files throw this error:NotImplementedError: Conversion factor for converting PROPCPS to BQML is not implemented
Overall, the package functionality works seamlessly and is easy to use and interpret for the user.
Thank you for your great work with this package and the ease with which DICOM files are parsed and processed.