Error when loading MRB

I repeatedly receive the following error when loading an MRB I saved yesterday evening. Amy support would be helpful:

Slicer has caught an application error, please save your work and restart.

If you have a repeatable sequence of steps that causes this message, please report the issue following instructions available at

The message detail is:

Exception thrown in event: D:\D\S\Slicer-1-build\ITK\Modules\IO\NRRD\src\itkNrrdImageIO.cxx:767:

itk::ERROR: itk::ERROR: NrrdImageIO(000001F4CA489030): Read: Error reading C:/Users/Benjamin Colbert/AppData/Local/NA-MIC/Slicer/cache/SlicerIO/__BundleLoadTemp-2022-02-10_073712_461/2022-02-09-Scene/Data/Segmentation.seg.nrrd:

[nrrd] nrrdLoad: trouble reading “C:/Users/Benjamin Colbert/AppData/Local/NA-MIC/Slicer/cache/SlicerIO/__BundleLoadTemp-2022-02-10_073712_461/2022-02-09-Scene/Data/Segmentation.seg.nrrd”

[nrrd] nrrdRead: trouble

[nrrd] _nrrdRead: trouble reading NRRD file

[nrrd] _nrrdFormatNRRD_read:

[nrrd] _nrrdEncodingRaw_read: fread got only 3228075008 1-sized things, not 7523042304 (42.9092% of expected)

The segmentation file is expected to be an extremely large file, about 7.5GB, but the actual file size is just 3.2GB.

Make sure there is enough free space on your hard disk (10x more than the mrb file size) and try again.

Saving such large files can be challenging, because you may run out of memory or disk space during saving and if you use a virtual file system (network drive, Virtual cloud drive - such as box or Google) then network connectivity and synchronization issues may affect the saving as well.

What Slicer version did you use? Did you use the same computer for saving and loading the scene? How big is the mrb file? How much free disk space you had when you saved the scene? How much physical RAM do you have in your computer and how much virtual memory have your configured in your Windows system settings?

What Slicer version did you use?


Did you use the same computer for saving and loading the scene?


How big is the mrb file?

6.01 GB

How much free disk space you had when you saved the scene?

Saving on a 4tb portable drive. The drive has >2.5TB left

How much physical RAM do you have in your computer and how much virtual memory have your configured in your Windows system settings?

I have 64gb ram installed and virtual memory is 9728mb

We have added extensive checking and error reporting during scene saving in recent Slicer Preview Releases. Unfortunately, these are not available in v4.11.20210226, so if there were errors during scene saving then it is possible that they were not reported.

Saving a 6GB file as MRB may require 10-20 GB temporary space in the temporary folder. This is usually set to a built-in drive, so having lots of space on an external drive may not matter.

Risk of file corruption is significantly increased for huge files and external drives. Since error reporting was limited in the Slicer version that you used and there were some risk factors, there is a chance that there was a failure during saving and it was not reported.

If you work with such huge files, I would recommend to save to the local disk first (and use the external disk for archival), save to mrml (not single-file mrb, to avoid huge files), and use latest Slicer Preview Release for improved error detection and reporting.

It’s a good thing this only had a couple of hours of work associated with it. Makes it a cheap lesson.

So question, if I am using a the imagestack tool within the SlicerMorph toolkit and only loading a ROI at full resolution (e.g., load the whole stack as preview resolution, then slect area around structure of interest) is that captured in mrml. Apologize for the basic question but I am the only one in my lab doing this work so don’t really know the best practices.

When you use ImageStacks it will by default use the same target volume in the MRML scene as you change import parameters so you tests won’t be saved, only the last one you import.

We have quite a bit of training material around SLicerMorph tools. You may want to review them quickly:

I will second @lassoan suggestion not to use the MRB format when working locally, but use it when you need to send data to share data. I also suggest not bothering to compress the data, since it adds a quite a bit of time to your saving process (for large datasets) and nowadays usually storage is so cheap.

If you do NOT have a complex scene (with lots of different things like segmentations, markups, tables, rendering etc), you can also use the export As function (right click on the object in the Data module, and choose Export As) to manually save your objects one by one. This works fine for simple workflows, but gets tedious quickly when you a lot of things and you export them one by one.

In Slicer Preview Release we have a built-in Export to file... menu action. It has several advantages over the prototype Export as... action, including the ability to export all the nodes in a folder at once, so if you export many markups.

@muratmaga could you disable Export as... for Slicer-4.13 to avoid confusing users with the duplicate export option?

1 Like

Not yet. We will. Thanks for the remainder


Thanks @muratmaga and @lassoan, I have updated our extension to remove “ExportAs”.