Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Handling of mismatched size mask is still not working #259

Closed
fedorov opened this issue May 24, 2017 · 2 comments · Fixed by #260
Closed

Handling of mismatched size mask is still not working #259

fedorov opened this issue May 24, 2017 · 2 comments · Fixed by #260
Labels

Comments

@fedorov
Copy link
Collaborator

fedorov commented May 24, 2017

I think the issue is that the resampled mask does not get propagated from here: https://github.com/Radiomics/pyradiomics/blob/master/radiomics/imageoperations.py#L238

checkMask returns the bounding box for the resampled mask here: https://github.com/Radiomics/pyradiomics/blob/master/radiomics/featureextractor.py#L326

But cropToTumorMask is operating on the original mask before resampling: https://github.com/Radiomics/pyradiomics/blob/master/radiomics/featureextractor.py#L340

Identified by Dev Gude.

@fedorov fedorov added the bug label May 24, 2017
@fedorov
Copy link
Collaborator Author

fedorov commented May 25, 2017

@JoostJM I suggest to fix this by having checkMask return a tuple of bounding box and an updated mask, if it had to be resampled, and then use that updated mask after the mask check. Do you have objections?

fedorov added a commit to fedorov/pyradiomics that referenced this issue May 25, 2017
This resolves AIM-Harvard#259

In the situation when the mask was corrected to compensate for the differences
between the image and mask geometry, the updated mask was not propagated to be
used for feature calculation.
@JoostJM
Copy link
Collaborator

JoostJM commented May 25, 2017 via email

fedorov added a commit to fedorov/pyradiomics that referenced this issue May 29, 2017
This resolves AIM-Harvard#259

In the situation when the mask was corrected to compensate for the differences
between the image and mask geometry, the updated mask was not propagated to be
used for feature calculation.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants