Merged
Conversation
Enet4
requested changes
May 25, 2024
Owner
Enet4
left a comment
There was a problem hiding this comment.
Thank you for reviving this PR. I found one issue, but it should be ready after the fix.
Contributor
Author
|
Hello, Thanks for taking the time to review and for your feedback. Nice catch indeed, however I'm confused because I have extensionless files in my test set and it doesn't panic while it should (at least I thought unwrapping a None value was panicking). In any case, your fix works perfectly fine so I'll commit it without |
3378970 to
8971372
Compare
Enet4
approved these changes
Jun 4, 2024
Owner
Enet4
left a comment
There was a problem hiding this comment.
I believe we're ready to bring this in. The proposed functionality enables bulk conversions without affecting CLI usage for converting files one at a time.
Thanks again!
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Hi,
I worked on this a few month ago (#397) but I lacked time to finish it. Today I wanted to finish it and somehow messed my merge so I closed the other PR and reopened this clean one from main/master.
The basic functionalities of bulk conversion work fine while retaining the previous behavior.
The user can pass a single file, a folder or several files.
If a single file is passed, the user can specify an output file name with the extension.
If there are multiple files (or several files collected in the folder) the user can optionally pass an output directory where the images will be stored. The user can also optionally pass a target extension for the images.
If a folder is passed, it can be searched recursively for dicom files.
The function
convert_single_file()is a bit clumsy because we wanted to retain the previous behavior of being able to rename the output file when passing a single file.I could add some other functionalities but I wanted to check with you first if it was worth doing, notably:
frame_numberbehavior)Please tell me if this is what you had in mind in #343 and what should be modified to be able to merge.
Thanks