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

FIX: Correct a number of problems introduced by changes for MIALSRTK v2.0.2 #110

Merged
merged 61 commits into from
Nov 2, 2021

Conversation

pdedumast
Copy link
Member

@pdedumast pdedumast commented Sep 1, 2021

This PR proposes a number of changes that should correct all the problems introduced by PR #70 already merged into master for version 2.0.2. In particular, it includes:

pdedumast and others added 30 commits September 1, 2021 12:08
…x_stuck_running_nodes

Temporary fix for nipype nodes stuckes in running state. 
Remove specification of number of processes (n_procs) to run the workflow
…tion interface to prevent Segmentation Fault
@sebastientourbier
Copy link
Member

@pdedumast I was indeed about to get to you about that! Doing so would act more as a refinement process, as for each new iteration, we initialize the transforms and update the reference image from the ones obtained from the previous iteration. But yes for sure, let's see how this works! 👌

@sebastientourbier
Copy link
Member

sebastientourbier commented Oct 27, 2021

@pdedumast The idea needs in fact to be better implemented as now the step length decreases after each iteration AND each image... which is wrong :/ So I got back to your old implmentation i.e. dividing by 4 the default values once and for all.

@sebastientourbier sebastientourbier changed the title REL: MIALSRTK v2.0.3 FIX: Correct a number of problems introduced by changes for MIALSRTK v2.0.2 Oct 27, 2021
@pdedumast
Copy link
Member Author

@sebastientourbier, based on the few tests I've made, reducing only once the registration step length seems enough to avoid slices that get completely lost. Though, further investigation might still be helpful to improve that.

Note: It seems that starting with big step length and then reducing it is not the correct strategy. I have observed strongly misregistered slices this way. That's why keeping a constant and not to large step lengths seems appropriate for now.

Copy link
Member

@sebastientourbier sebastientourbier left a comment

Choose a reason for hiding this comment

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

@pdedumast Just reviewed all the changes and it seems we are almost ready for the merge! But I noticed there is still a bug in the last execution of test 01 on circleci. When the pipeline is executed with the manual masks, a list of images defined by "stacks" in the param file, and the stackordering, all the images are then considered, while one would expect to take only the list of images defined by "stacks" in the param file.

… by "stacks" in the param file right after the datagrabber for masks
@sebastientourbier
Copy link
Member

@pdedumast I should have fixed the issue with the last commit cb7b769.

I added a preprocess.FilteringByRunid interface right after the datagrabber for the masks:

if self.m_stacks is not None:
custom_masks_filter = Node(interface=preprocess.FilteringByRunid(),
name='custom_masks_filter')
custom_masks_filter.inputs.stacks_id = self.m_stacks

and review the inputs/outputs connection of nodes:

if self.use_manual_masks:
if self.m_stacks is not None:
self.wf.connect(dg, "masks", custom_masks_filter, "input_files")
self.wf.connect(custom_masks_filter, "output_files", brainMask, "out_file")
else:
self.wf.connect(dg, "masks", brainMask, "out_file")

Copy link
Member

@sebastientourbier sebastientourbier left a comment

Choose a reason for hiding this comment

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

All tests passed on circleci for the lastest commit and after reviewing the changes introduced, this PR looks ready to be merged! Just wait from you to give me the go-head 👍
@hamzake: Could you test the singularity image built by circleci based on the latest commit (fea1a63): https://2023-210386291-gh.circle-artifacts.com/0/tmp/cache/mialsuperresolutiontoolkit.simg ?
@pdedumast: Have you noticed any issue that would need to be addressed in this PR before merging?

@pdedumast
Copy link
Member Author

@sebastientourbier, looks good to me ! 👌

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants