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

sct_register_multimodal: Fixed bug when using partial mask with algo=slicereg #1917

Merged
merged 12 commits into from
Jul 14, 2018

Conversation

jcohenadad
Copy link
Member

Description of the Change

Fixes #1666

@jcohenadad jcohenadad changed the title (WIP) sct_register_multimodal: Fixed bug when using partial mask with algo=slicereg sct_register_multimodal: Fixed bug when using partial mask with algo=slicereg Jul 12, 2018
@jcohenadad jcohenadad requested a review from zougloub July 12, 2018 02:33
@jcohenadad
Copy link
Member Author

jcohenadad commented Jul 12, 2018

tricky blockage with integrity testing of sct_label_utils, commit 6835997:

On Travis/Linux/Python2.7/Miniconda2:

   Value = 1 : (30.5004844961, 27.6019864341, 25.0966569767) --> ( 31.0, 28.0, 25.0)

On my macbook (OSX 10.13):

   Value = 1 : (30.535540409, 27.4919668939, 25.1063777994) --> ( 31.0, 27.0, 25.0)

this needs to be fixed before merging.

UPDATE 2018-07-11 22.53: my mistake ( i had a corrupted testing data)

Copy link
Contributor

@zougloub zougloub left a comment

Choose a reason for hiding this comment

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

Commenting on code only: looks OK, but I have one nifty suggestion (feel free to pull/fixup).

continue_zmin_search = False
# the following if statement deals with zmax search
if np.any(dataz > threshold):
zmax = iz
Copy link
Contributor

Choose a reason for hiding this comment

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

I had to take a few minutes to do this and this which should totally blow your mind (if it works... totally untested).

Copy link
Member Author

Choose a reason for hiding this comment

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

nice! it works and it does blow my mind (i have a low threshold). I'll merge cJ/msct_image-new-slicer-that-blows-your-mind on jca/1666.

@jcohenadad jcohenadad added this to the v3.2.3 milestone Jul 12, 2018
@jcohenadad jcohenadad merged commit ed7d66b into master Jul 14, 2018
@jcohenadad jcohenadad deleted the jca/1666 branch July 14, 2018 15:04
@jcohenadad jcohenadad added the bug category: fixes an error in the code label Jul 21, 2018
jcohenadad added a commit that referenced this pull request Dec 18, 2019
…slicereg (#1917)

* fixed indent for PEP8

* refactored msct_image.find_zmin_zmax: need to udpate register_to_template (WIP)

* now account for mask coverage when cropping before slicereg (fixes #1666)

* fixed compatibility of register_to_template with recent modification find_zmin_zmax()

* TEST: label_utils: updated results due to change in numerical precision

* cleanup

* TEST: reverted back to previous integrity testing value (my mistake)

* msct_image: add a slicer!

* improve find_zmin_zmax() with slicer magic

* msct_image: fixup typo (please squash)


Former-commit-id: ed7d66b
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug category: fixes an error in the code
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants