Freesurfer annotation file crashes model module

i tried to load a freesurfer surface lh.pial and then add the lh.aparc.a2009s.annot file to show parcellation which loaded and displayed well but when i touched the model scene selector to turn the model off slicer crashed. see bug report below.

[DEBUG][Qt] 24.05.2017 20:30:19 [] (unknown:0) - Session start time .......: 2017-05-24 20:30:19
[DEBUG][Qt] 24.05.2017 20:30:19 [] (unknown:0) - Slicer version ...........: 4.7.0-2017-05-23 (revision 26032) macosx-amd64 - installed
[DEBUG][Qt] 24.05.2017 20:30:19 [] (unknown:0) - Operating system .........: Mac OS X / 10.11.6 / 15G1510 - 64-bit
[DEBUG][Qt] 24.05.2017 20:30:19 [] (unknown:0) - Memory ...................: 32768 MB physical, 11264 MB virtual
[DEBUG][Qt] 24.05.2017 20:30:19 [] (unknown:0) - CPU ......................: GenuineIntel Intel(R) Core(TM) i7-6700K CPU @ 4.00GHz, 4 cores, 8 logical processors
[DEBUG][Qt] 24.05.2017 20:30:19 [] (unknown:0) - Developer mode enabled ...: no
[DEBUG][Qt] 24.05.2017 20:30:19 [] (unknown:0) - Prefer executable CLI ....: yes
[DEBUG][Qt] 24.05.2017 20:30:19 [] (unknown:0) - Additional module paths ..: /Applications/Slicer_dev_5-24.app/Contents/Extensions-26032/DTIProcess/lib/Slicer-4.7/cli-modules, /Applications/Slicer_dev_5-24.app/Contents/Extensions-26032/UKFTractography/lib/Slicer-4.7/cli-modules, /Applications/Slicer_dev_5-24.app/Contents/Extensions-26032/SlicerDMRI/lib/Slicer-4.7/cli-modules, /Applications/Slicer_dev_5-24.app/Contents/Extensions-26032/SlicerDMRI/lib/Slicer-4.7/qt-loadable-modules, /Applications/Slicer_dev_5-24.app/Contents/Extensions-26032/SlicerDMRI/lib/Slicer-4.7/qt-scripted-modules, /Applications/Slicer_dev_5-24.app/Contents/Extensions-26032/ResampleDTIlogEuclidean/lib/Slicer-4.7/cli-modules, /Applications/Slicer_dev_5-24.app/Contents/Extensions-26032/Sequences/lib/Slicer-4.7/qt-loadable-modules, /Applications/Slicer_dev_5-24.app/Contents/Extensions-26032/SegmentEditorExtraEffects/lib/Slicer-4.7/qt-scripted-modules
[DEBUG][Python] 24.05.2017 20:30:25 [Python] (/Applications/Slicer_dev_5-24.app/Contents/lib/Slicer-4.7/qt-scripted-modules/SubjectHierarchyPlugins/AbstractScriptedSubjectHierarchyPlugin.py:36) - Scripted subject hierarchy plugin registered: Annotations
[DEBUG][Python] 24.05.2017 20:30:26 [Python] (/Applications/Slicer_dev_5-24.app/Contents/lib/Slicer-4.7/qt-scripted-modules/SubjectHierarchyPlugins/AbstractScriptedSubjectHierarchyPlugin.py:36) - Scripted subject hierarchy plugin registered: SegmentEditor
[DEBUG][Python] 24.05.2017 20:30:26 [Python] (/Applications/Slicer_dev_5-24.app/Contents/lib/Slicer-4.7/qt-scripted-modules/SubjectHierarchyPlugins/AbstractScriptedSubjectHierarchyPlugin.py:36) - Scripted subject hierarchy plugin registered: SegmentStatistics
[DEBUG][Qt] 24.05.2017 20:30:21 [] (unknown:0) - Number of registered modules: 169
[CRITICAL][Qt] 24.05.2017 20:30:22 [] (unknown:0) -   Error(s):
    CLI executable: /Applications/Slicer_dev_5-24.app/Contents/Extensions-26032/DTIProcess/lib/Slicer-4.7/cli-modules/polydatamerge
    dyld: Library not loaded: @rpath/lib/Slicer-4.7/libjsoncpp.0.dylib
  Referenced from: /Applications/Slicer_dev_5-24.app/Contents/Extensions-26032/DTIProcess/lib/Slicer-4.7/cli-modules/polydatamerge
  Reason: image not found

    CLI executable: /Applications/Slicer_dev_5-24.app/Contents/Extensions-26032/DTIProcess/lib/Slicer-4.7/cli-modules/polydatamerge
    Failed to retrieve Xml Description
[CRITICAL][Qt] 24.05.2017 20:30:22 [] (unknown:0) - Fail to instantiate module  "polydatamerge"
[CRITICAL][Qt] 24.05.2017 20:30:22 [] (unknown:0) -   Error(s):
    CLI executable: /Applications/Slicer_dev_5-24.app/Contents/Extensions-26032/DTIProcess/lib/Slicer-4.7/cli-modules/polydatatransform
    dyld: Library not loaded: @rpath/lib/Slicer-4.7/libjsoncpp.0.dylib
  Referenced from: /Applications/Slicer_dev_5-24.app/Contents/Extensions-26032/DTIProcess/lib/Slicer-4.7/cli-modules/polydatatransform
  Reason: image not found

    CLI executable: /Applications/Slicer_dev_5-24.app/Contents/Extensions-26032/DTIProcess/lib/Slicer-4.7/cli-modules/polydatatransform
    Failed to retrieve Xml Description
[CRITICAL][Qt] 24.05.2017 20:30:22 [] (unknown:0) - Fail to instantiate module  "polydatatransform"
[DEBUG][Qt] 24.05.2017 20:30:22 [] (unknown:0) - Number of instantiated modules: 167
[WARNING][Qt] 24.05.2017 20:30:25 [] (unknown:0) - When loading module  "CLIEventTest" , the dependency "CLI4Test" failed to be loaded.
[INFO][Stream] 24.05.2017 20:30:25 [] (unknown:0) - Initializing terminology mapping for map file /Applications/Slicer_dev_5-24.app/Contents/share/Slicer-4.7/ColorFiles/Terminology//GenericAnatomyColors-SNOMED.csv
[INFO][Stream] 24.05.2017 20:30:25 [] (unknown:0) - 288 terms were read for Slicer LUT GenericAnatomyColors
[WARNING][Qt] 24.05.2017 20:30:26 [] (unknown:0) - When loading module  "TwoCLIsInARowTest" , the dependency "CLI4Test" failed to be loaded.
[WARNING][Qt] 24.05.2017 20:30:26 [] (unknown:0) - When loading module  "TwoCLIsInParallelTest" , the dependency "CLI4Test" failed to be loaded.
[DEBUG][Qt] 24.05.2017 20:30:26 [] (unknown:0) - Number of loaded modules: 164
[DEBUG][Qt] 24.05.2017 20:30:26 [] (unknown:0) - Switch to module:  "Welcome"
[CRITICAL][FD] 24.05.2017 20:32:27 [] (unknown:0) - 2017-05-24 20:32:27.298 Slicer[4663:1738626] modalSession has been exited prematurely - check for a reentrant call to endModalSession:
[CRITICAL][FD] 24.05.2017 20:32:32 [] (unknown:0) - 2017-05-24 20:32:32.970 Slicer[4663:1738626] modalSession has been exited prematurely - check for a reentrant call to endModalSession:
[DEBUG][Qt] 24.05.2017 20:32:33 [] (unknown:0) - "Model" Reader has successfully read the file "/Users/mrjeffs/Desktop/nbwr/Slicer_scenes/Slicer_whole_br_UKF_lt-SLF-IFOF_qT1-05-24-2017_6pm/lh.pial" "[0.19s]"
[CRITICAL][FD] 24.05.2017 20:32:45 [] (unknown:0) - 2017-05-24 20:32:45.591 Slicer[4663:1738626] modalSession has been exited prematurely - check for a reentrant call to endModalSession:
[DEBUG][Qt] 24.05.2017 20:32:45 [] (unknown:0) - qSlicerScalarOverlayReader::options(): 0x11127b640
[CRITICAL][FD] 24.05.2017 20:32:51 [] (unknown:0) - 2017-05-24 20:32:51.383 Slicer[4663:1738626] modalSession has been exited prematurely - check for a reentrant call to endModalSession:
[DEBUG][Qt] 24.05.2017 20:32:51 [] (unknown:0) - "Scalar Overlay" Reader has successfully read the file "/Users/mrjeffs/Desktop/nbwr/Slicer_scenes/Slicer_whole_br_UKF_lt-SLF-IFOF_qT1-05-24-2017_6pm/lh.aparc.a2009s.annot" "[0.03s]"
[ERROR][VTK] 24.05.2017 20:32:51 [vtkLookupTable (0x131019a40)] (/Users/kitware/Dashboards/Nightly/Slicer-0-build/VTKv7/Common/Core/vtkLookupTable.cxx:144) - Bad table range: [1e+299, -1e+299]
[DEBUG][Qt] 24.05.2017 20:32:56 [] (unknown:0) - Switch to module:  "Models"
[ERROR][VTK] 24.05.2017 20:33:02 [vtkLookupTable (0x131019a40)] (/Users/kitware/Dashboards/Nightly/Slicer-0-build/VTKv7/Common/Core/vtkLookupTable.cxx:144) - Bad table range: [1e+299, -1e+299]

and this log:

[DEBUG][Qt] 24.05.2017 20:23:56 [] (unknown:0) - Session start time .......: 2017-05-24 20:23:56
[DEBUG][Qt] 24.05.2017 20:23:56 [] (unknown:0) - Slicer version ...........: 4.7.0-2017-05-23 (revision 26032) macosx-amd64 - installed
[DEBUG][Qt] 24.05.2017 20:23:56 [] (unknown:0) - Operating system .........: Mac OS X / 10.11.6 / 15G1510 - 64-bit
[DEBUG][Qt] 24.05.2017 20:23:56 [] (unknown:0) - Memory ...................: 32768 MB physical, 11264 MB virtual
[DEBUG][Qt] 24.05.2017 20:23:56 [] (unknown:0) - CPU ......................: GenuineIntel Intel(R) Core(TM) i7-6700K CPU @ 4.00GHz, 4 cores, 8 logical processors
[DEBUG][Qt] 24.05.2017 20:23:56 [] (unknown:0) - Developer mode enabled ...: no
[DEBUG][Qt] 24.05.2017 20:23:56 [] (unknown:0) - Prefer executable CLI ....: yes
[DEBUG][Qt] 24.05.2017 20:23:56 [] (unknown:0) - Additional module paths ..: /Applications/Slicer_dev_5-24.app/Contents/Extensions-26032/DTIProcess/lib/Slicer-4.7/cli-modules, /Applications/Slicer_dev_5-24.app/Contents/Extensions-26032/UKFTractography/lib/Slicer-4.7/cli-modules, /Applications/Slicer_dev_5-24.app/Contents/Extensions-26032/SlicerDMRI/lib/Slicer-4.7/cli-modules, /Applications/Slicer_dev_5-24.app/Contents/Extensions-26032/SlicerDMRI/lib/Slicer-4.7/qt-loadable-modules, /Applications/Slicer_dev_5-24.app/Contents/Extensions-26032/SlicerDMRI/lib/Slicer-4.7/qt-scripted-modules, /Applications/Slicer_dev_5-24.app/Contents/Extensions-26032/ResampleDTIlogEuclidean/lib/Slicer-4.7/cli-modules, /Applications/Slicer_dev_5-24.app/Contents/Extensions-26032/Sequences/lib/Slicer-4.7/qt-loadable-modules, /Applications/Slicer_dev_5-24.app/Contents/Extensions-26032/SegmentEditorExtraEffects/lib/Slicer-4.7/qt-scripted-modules
[DEBUG][Python] 24.05.2017 20:24:02 [Python] (/Applications/Slicer_dev_5-24.app/Contents/lib/Slicer-4.7/qt-scripted-modules/SubjectHierarchyPlugins/AbstractScriptedSubjectHierarchyPlugin.py:36) - Scripted subject hierarchy plugin registered: Annotations
[DEBUG][Python] 24.05.2017 20:24:03 [Python] (/Applications/Slicer_dev_5-24.app/Contents/lib/Slicer-4.7/qt-scripted-modules/SubjectHierarchyPlugins/AbstractScriptedSubjectHierarchyPlugin.py:36) - Scripted subject hierarchy plugin registered: SegmentEditor
[DEBUG][Python] 24.05.2017 20:24:03 [Python] (/Applications/Slicer_dev_5-24.app/Contents/lib/Slicer-4.7/qt-scripted-modules/SubjectHierarchyPlugins/AbstractScriptedSubjectHierarchyPlugin.py:36) - Scripted subject hierarchy plugin registered: SegmentStatistics
[DEBUG][Qt] 24.05.2017 20:23:59 [] (unknown:0) - Number of registered modules: 169
[CRITICAL][Qt] 24.05.2017 20:23:59 [] (unknown:0) -   Error(s):
    CLI executable: /Applications/Slicer_dev_5-24.app/Contents/Extensions-26032/DTIProcess/lib/Slicer-4.7/cli-modules/polydatamerge
    dyld: Library not loaded: @rpath/lib/Slicer-4.7/libjsoncpp.0.dylib
  Referenced from: /Applications/Slicer_dev_5-24.app/Contents/Extensions-26032/DTIProcess/lib/Slicer-4.7/cli-modules/polydatamerge
  Reason: image not found

    CLI executable: /Applications/Slicer_dev_5-24.app/Contents/Extensions-26032/DTIProcess/lib/Slicer-4.7/cli-modules/polydatamerge
    Failed to retrieve Xml Description
[CRITICAL][Qt] 24.05.2017 20:23:59 [] (unknown:0) - Fail to instantiate module  "polydatamerge"
[CRITICAL][Qt] 24.05.2017 20:23:59 [] (unknown:0) -   Error(s):
    CLI executable: /Applications/Slicer_dev_5-24.app/Contents/Extensions-26032/DTIProcess/lib/Slicer-4.7/cli-modules/polydatatransform
    dyld: Library not loaded: @rpath/lib/Slicer-4.7/libjsoncpp.0.dylib
  Referenced from: /Applications/Slicer_dev_5-24.app/Contents/Extensions-26032/DTIProcess/lib/Slicer-4.7/cli-modules/polydatatransform
  Reason: image not found

    CLI executable: /Applications/Slicer_dev_5-24.app/Contents/Extensions-26032/DTIProcess/lib/Slicer-4.7/cli-modules/polydatatransform
    Failed to retrieve Xml Description
[CRITICAL][Qt] 24.05.2017 20:23:59 [] (unknown:0) - Fail to instantiate module  "polydatatransform"
[DEBUG][Qt] 24.05.2017 20:23:59 [] (unknown:0) - Number of instantiated modules: 167
[WARNING][Qt] 24.05.2017 20:24:02 [] (unknown:0) - When loading module  "CLIEventTest" , the dependency "CLI4Test" failed to be loaded.
[INFO][Stream] 24.05.2017 20:24:02 [] (unknown:0) - Initializing terminology mapping for map file /Applications/Slicer_dev_5-24.app/Contents/share/Slicer-4.7/ColorFiles/Terminology//GenericAnatomyColors-SNOMED.csv
[INFO][Stream] 24.05.2017 20:24:02 [] (unknown:0) - 288 terms were read for Slicer LUT GenericAnatomyColors
[WARNING][Qt] 24.05.2017 20:24:03 [] (unknown:0) - When loading module  "TwoCLIsInARowTest" , the dependency "CLI4Test" failed to be loaded.
[WARNING][Qt] 24.05.2017 20:24:03 [] (unknown:0) - When loading module  "TwoCLIsInParallelTest" , the dependency "CLI4Test" failed to be loaded.
[DEBUG][Qt] 24.05.2017 20:24:03 [] (unknown:0) - Number of loaded modules: 164
[DEBUG][Qt] 24.05.2017 20:24:03 [] (unknown:0) - Switch to module:  "Welcome"
[CRITICAL][FD] 24.05.2017 20:24:14 [] (unknown:0) - 2017-05-24 20:24:14.308 Slicer[4639:1726512] modalSession has been exited prematurely - check for a reentrant call to endModalSession:
[CRITICAL][FD] 24.05.2017 20:24:16 [] (unknown:0) - 2017-05-24 20:24:16.053 Slicer[4639:1726512] modalSession has been exited prematurely - check for a reentrant call to endModalSession:
[DEBUG][Qt] 24.05.2017 20:24:16 [] (unknown:0) - "Model" Reader has successfully read the file "/Users/mrjeffs/Desktop/nbwr/Slicer_scenes/Slicer_whole_br_UKF_lt-SLF-IFOF_qT1-05-24-2017_6pm/rh.white" "[0.19s]"
[DEBUG][Qt] 24.05.2017 20:24:18 [] (unknown:0) - Switch to module:  "Models"
[CRITICAL][FD] 24.05.2017 20:24:29 [] (unknown:0) - 2017-05-24 20:24:29.722 Slicer[4639:1726512] modalSession has been exited prematurely - check for a reentrant call to endModalSession:
[DEBUG][Qt] 24.05.2017 20:24:29 [] (unknown:0) - qSlicerScalarOverlayReader::options(): 0x11bc4b4a0

Would be able to share the dataset causing the crash ?

removed links, annot now loads fine, however edited lh.thickness fails to load.

Thanks for reporting this. The hang is due to a recent change in Models module (in computing display precision for scalar range). I’ve prepared a fix: https://github.com/Slicer/Slicer/pull/728

The fix will be available in tomorrow’s nightly build.

awesome, thanks guys, or merci. jeff

tested june 1 and annotation loads but i tried loading a modified lh.thickness file and it failed to load in slicer tho freeview works fine.
copy of debug:
[DEBUG][Qt] 01.06.2017 16:08:48 [] (unknown:0) - Session start time …: 2017-06-01 16:08:48
[DEBUG][Qt] 01.06.2017 16:08:48 [] (unknown:0) - Slicer version …: 4.7.0-2017-05-31 (revision 26062) macosx-amd64 - installed
[DEBUG][Qt] 01.06.2017 16:08:48 [] (unknown:0) - Operating system …: Mac OS X / 10.11.6 / 15G1510 - 64-bit
[DEBUG][Qt] 01.06.2017 16:08:48 [] (unknown:0) - Memory …: 32768 MB physical, 17408 MB virtual
[DEBUG][Qt] 01.06.2017 16:08:48 [] (unknown:0) - CPU …: GenuineIntel Intel® Core™ i7-6700K CPU @ 4.00GHz, 4 cores, 8 logical processors
[DEBUG][Qt] 01.06.2017 16:08:48 [] (unknown:0) - Developer mode enabled …: no
[DEBUG][Qt] 01.06.2017 16:08:48 [] (unknown:0) - Prefer executable CLI …: yes
[DEBUG][Qt] 01.06.2017 16:08:48 [] (unknown:0) - Additional module paths …: (none)
[DEBUG][Python] 01.06.2017 16:08:53 [Python] (/Applications/Slicer_4p7p0_dev06-01-2017.app/Contents/lib/Slicer-4.7/qt-scripted-modules/SubjectHierarchyPlugins/AbstractScriptedSubjectHierarchyPlugin.py:36) - Scripted subject hierarchy plugin registered: Annotations
[DEBUG][Python] 01.06.2017 16:08:53 [Python] (/Applications/Slicer_4p7p0_dev06-01-2017.app/Contents/lib/Slicer-4.7/qt-scripted-modules/SubjectHierarchyPlugins/AbstractScriptedSubjectHierarchyPlugin.py:36) - Scripted subject hierarchy plugin registered: SegmentEditor
[DEBUG][Python] 01.06.2017 16:08:53 [Python] (/Applications/Slicer_4p7p0_dev06-01-2017.app/Contents/lib/Slicer-4.7/qt-scripted-modules/SubjectHierarchyPlugins/AbstractScriptedSubjectHierarchyPlugin.py:36) - Scripted subject hierarchy plugin registered: SegmentStatistics
[DEBUG][Qt] 01.06.2017 16:08:50 [] (unknown:0) - Number of registered modules: 137
[DEBUG][Qt] 01.06.2017 16:08:50 [] (unknown:0) - Number of instantiated modules: 137
[INFO][Stream] 01.06.2017 16:08:53 [] (unknown:0) - Initializing terminology mapping for map file /Applications/Slicer_4p7p0_dev06-01-2017.app/Contents/share/Slicer-4.7/ColorFiles/Terminology//GenericAnatomyColors-SNOMED.csv
[INFO][Stream] 01.06.2017 16:08:53 [] (unknown:0) - 288 terms were read for Slicer LUT GenericAnatomyColors
[DEBUG][Qt] 01.06.2017 16:08:54 [] (unknown:0) - Number of loaded modules: 137
[DEBUG][Qt] 01.06.2017 16:08:54 [] (unknown:0) - Switch to module: “Welcome”
[CRITICAL][FD] 01.06.2017 16:09:30 [] (unknown:0) - 2017-06-01 16:09:30.337 Slicer[19903:8055473] modalSession has been exited prematurely - check for a reentrant call to endModalSession:
[CRITICAL][FD] 01.06.2017 16:09:32 [] (unknown:0) - 2017-06-01 16:09:32.667 Slicer[19903:8055473] modalSession has been exited prematurely - check for a reentrant call to endModalSession:
[DEBUG][Qt] 01.06.2017 16:09:32 [] (unknown:0) - “Model” Reader has successfully read the file “/Users/mrjeffs/Desktop/template_hires_br_freesurf_v6/surf/lh.pial” “[0.18s]”
[CRITICAL][FD] 01.06.2017 16:09:44 [] (unknown:0) - 2017-06-01 16:09:44.919 Slicer[19903:8055473] modalSession has been exited prematurely - check for a reentrant call to endModalSession:
[DEBUG][Qt] 01.06.2017 16:09:44 [] (unknown:0) - qSlicerScalarOverlayReader::options(): 0x11095abf0
[CRITICAL][FD] 01.06.2017 16:09:56 [] (unknown:0) - 2017-06-01 16:09:56.472 Slicer[19903:8055473] modalSession has been exited prematurely - check for a reentrant call to endModalSession:
[DEBUG][Qt] 01.06.2017 16:10:00 [] (unknown:0) - Switch to module: “Models”
[CRITICAL][FD] 01.06.2017 16:12:28 [] (unknown:0) - 2017-06-01 16:12:28.208 Slicer[19903:8055473] modalSession has been exited prematurely - check for a reentrant call to endModalSession:
[CRITICAL][FD] 01.06.2017 16:12:48 [] (unknown:0) - 2017-06-01 16:12:48.153 Slicer[19903:8055473] modalSession has been exited prematurely - check for a reentrant call to endModalSession:
[DEBUG][Qt] 01.06.2017 16:12:48 [] (unknown:0) - qSlicerScalarOverlayReader::options(): 0x11095abf0
[CRITICAL][FD] 01.06.2017 16:12:51 [] (unknown:0) - 2017-06-01 16:12:51.082 Slicer[19903:8055473] modalSession has been exited prematurely - check for a reentrant call to endModalSession:
[DEBUG][Qt] 01.06.2017 16:12:51 [] (unknown:0) - “Scalar Overlay” Reader has successfully read the file “/Users/mrjeffs/Desktop/template_hires_br_freesurf_v6/label/lh.aparc.a2009s.annot” “[0.06s]”

here are the new files:
new thickness file:


a pial file:

The current version of Slicer can only load scalar overlays from files with standard file extensions. I’ve committed a fix that will allow loading scalar overlay files with any extension - this fix will be available in tomorrow’s nightly version.

Till then, if you rename your file to lh.thickness then it should load fine.

ah it was that simple. great. that will be helpful for our other modalities as well. thanks. jeff

I’ve tested this a bit more and unfortunately it has some side effects if we let any file extension to be recognized as FreeSurfer scalar overlay. Would it be an issue for you to save your overlay files with file extensions that ends with a standard extension? For example instead of lh.meanthickness_contrl these would all work: lh.contrl.mean.thickness, lh.mean_contrl.thickness, lh_mean_contrl.thickness.

no problem. makes sense to have it be limited. lh.some_contiguous_string.thickness works fine. it looks like there is an option for multiple scalars per model object, so may i also suggest an lh.some_contiguous_string.dspm,
and lh.some_contiguous_string.morph as a starting list.
off topic but is there a method to cycle thru an overlay in movie mode? that would be a very useful feature for
multi modal meg datasets
jeff

Do files with .dspm and .morph extension have the same format as .thickness files?

About the movie: I’ve created a separate topic to discuss that - see here

i think the better way is to deal directly with .stc files as overlays, .dspm static files would only be helpful once you have identified the critical time slice. so i ammend my feature request to .stc files and stabdard freesurfer morph files.