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

[REF] Refactor function clip_img #1392

Merged
merged 5 commits into from
Nov 26, 2024

Conversation

NicolasGensollen
Copy link
Member

@NicolasGensollen NicolasGensollen commented Nov 22, 2024

Follow-up PR of #1355

This PR proposes to:

  • Add a new clip_nifti function to clinica.utils.image for generic clipping of nifty images
  • Refactor clip_img to use clip_nifti with the computed threshold
  • Provide the pipeline base directory as the output_dir of the clipping task such that clipped images aren't written in the current folder.
  • Add unit tests for function clip_nifti and clip_img

@NicolasGensollen NicolasGensollen self-assigned this Nov 22, 2024
@NicolasGensollen NicolasGensollen marked this pull request as ready for review November 25, 2024 13:46
Copy link
Contributor

@AliceJoubert AliceJoubert left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM thanks @NicolasGensollen ! I don't remember if the clip was to be an option or not. In any case, the documentation should be updated to indicate that now we clip images :-)

@NicolasGensollen
Copy link
Member Author

Thanks for the review @AliceJoubert !
The clipping of the background is not implemented as an option at the moment. I don't believe we want to do that (but we totally can do it if needed).
I agree with you that we need to update the doc of the pipeline to explain that backgrounds are now clipped (will do that in a dedicated PR), thanks for thinking about that !

@NicolasGensollen NicolasGensollen merged commit 6514b57 into aramis-lab:dev Nov 26, 2024
12 of 14 checks passed
@NicolasGensollen NicolasGensollen deleted the refactor-clip_img branch November 26, 2024 10:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants