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

Possible ants bracket expansion bug #96

Open
jarodroland opened this issue Aug 22, 2023 · 0 comments
Open

Possible ants bracket expansion bug #96

jarodroland opened this issue Aug 22, 2023 · 0 comments
Labels
bug Something isn't working

Comments

@jarodroland
Copy link

What happened?

I ran into this error in the PostFreeSurfer stage that in searching looks like it may be related to an issue with ANTs known as the "bracket expansion bug": ANTsX/ANTs#712

What command did you use?

Routine Docker execution in PostFreeSurfer stage.

What version of the abcd-hcp pipeline are you using?

v0.1.0

Directory Structure

No response

Relevant log output

Truncated relevant portion from the 'AtlasRegistration to MNI152' section on calling /opt/ants/antsRegistrationSyN.sh

.
.
.
  PixelContainer:
    ImportImageContainer (0x4613b20)
      RTTI typeinfo:   itk::ImportImageContainer<unsigned long, double>
      Reference Count: 1
      Modified Time: 3052
      Debug: Off
      Object Name:
      Observers:
        none
      Pointer: 0x7f23dff9a010
      Container manages memory: true
      Size: 7221032
      Capacity: 7221032

     Weighting = 1
     Sampling strategy = none
     Number of bins = 32
     Radius = 4
     Sampling percentage  = 1
   Transform = SyN
     Gradient step = 0.1
     Update field sigma (voxel space) = 3
     Total field sigma (voxel space) = 0
     Update field time sigma = 0
     Total field time sigma  = 0
     Number of time indices = 0
     Number of time point samples = 0
Registration using 3 total stages.

Stage 0
  iterations = 2
  convergence threshold = 1e-06
  convergence window size = 10
  number of levels = 1
  using the Mattes MI metric (number of bins = 32, weight = 1)
  preprocessing:  winsorizing the image intensities



ERROR:  The number of shrink factors does not match the number of levels.
Shrink Factors: 4
Number Of Levels: 1



 antsApplyTransform

Add any additional information or context about the problem here.

I was able to work around by adding 'set -f' in the ansRegistrationSyN.sh script within the Docker container with the following command:
docker run -it --entrypoint=/bin/bash -v /data/bids:/bids_input -v /data/bids/derivatives/abcd-hcp-pipeline:/output -v /freesurfer-license.txt:/license.txt dcanumn/abcd-hcp-pipeline:v0.1.0 -c 'sed -i "2i set -f" /opt/ants/antsRegistrationSyN.sh; /entrypoint.sh /bids_input /output --freesurfer-license=/license.txt --ncpus 12 --participant-label 123 --session-id 01 --stage PostFreeSurfer:PostFreeSurfer'

You may want to consider updating the ANTs version in the Docker container.

@jarodroland jarodroland added the bug Something isn't working label Aug 22, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant