resolved bug, ITK-Snap can now open large images (> 4GB)

359 views
Skip to first unread message

Grothausmann, Roman Dr.

unread,
Jun 16, 2015, 10:04:20 AM6/16/15
to itksna...@googlegroups.com, itksn...@googlegroups.com
Dear mailing list members,


ITK-Snap crashed when opening large datasets. It seems this was caused by an
integer overflow when calculating a pointer index. The function used dot_product
from VNL, which does not check for overflows
(http://itk.org/gitweb?p=ITK.git;a=blob;f=Modules/ThirdParty/VNL/src/vxl/core/vnl/vnl_sse.h;h=04f930ef05bb49036e1fa69d6fe9ae9a697e2d45;hb=HEAD#l189).
Doing the calculation avoiding VNL allows to use a simple cast to size_t before
multiplication.
This solved the issue for me. I can now load a grey image of about 10GB plus a
40GB segmentation into ITK-Snap, modify it (even in gWS mode) and then render
the segmentation without any problems.
The fix can be found at:
https://github.com/pyushkevich/itksnap/pull/2

HTH
Roman

--
Dr. Roman Grothausmann

Tomographie und Digitale Bildverarbeitung
Tomography and Digital Image Analysis

Institut für Funktionelle und Angewandte Anatomie, OE 4120
Medizinische Hochschule Hannover
Carl-Neuberg-Str. 1
D-30625 Hannover

Tel. +49 511 532-2900

Dzenan Zukic

unread,
Jun 16, 2015, 11:22:32 AM6/16/15
to itksn...@googlegroups.com, itksna...@googlegroups.com, Paul Yushkevich, Paul Yushkevich
Dear Roman,

calculating the start voxel is a once per thread operation, which makes its speed negligible. The pull request should be merged.

Paul? Will you do it?

Regards

--
You received this message because you are subscribed to the Google Groups "itksnap-developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to itksnap-dev...@googlegroups.com.
To post to this group, send email to itksn...@googlegroups.com.
Visit this group at http://groups.google.com/group/itksnap-dev.
For more options, visit https://groups.google.com/d/optout.



--
Dženan Zukić, R&D Engineer, Kitware (Carrboro, NC Office)

moi ikka

unread,
Jun 16, 2015, 3:18:35 PM6/16/15
to itksna...@googlegroups.com, pyush...@gmail.com, pau...@mail.med.upenn.edu, itksn...@googlegroups.com
Dear administrators,

could you please incorporate the option to load bigger files to ITK-SNAP? I do not know how to use those external applications and as a beginner with this programme, I find it hard to use/learn them.

My files are not that big (200 megabytes, 260 images) and even when semiautomatically segmenting, the crash report appears.

Still, I do like ITK-SNAP. The crash report only hinders, not stops, the use. :)

Paul Yushkevich

unread,
Jun 17, 2015, 6:15:04 AM6/17/15
to Dzenan Zukic, itksn...@googlegroups.com, itksna...@googlegroups.com
Hi Roman

Thanks so much for this fix! I am committing now to the master branch (which will become the next release, 3.4)

Thanks!
Paul
--
Paul A. Yushkevich, Ph.D.
Associate Professor
Penn Image Computing and Science Laboratory
Department of Radiology
University of Pennsylvania

schnjph

unread,
Mar 20, 2017, 1:12:44 PM3/20/17
to itksnap-users, itksn...@googlegroups.com, grothausm...@mh-hannover.de
Dear all,

in the current version 3.6.0-rc1, ITK snap still crashes when I open large datasets. Is there a solution in the current version? Or should I downgrade to 3.4?
For details, please see my topic "large datasets".

Kind regards and thank you very much in advance.

JP

Paul Yushkevich

unread,
Mar 29, 2017, 5:19:49 AM3/29/17
to itksna...@googlegroups.com, itksn...@googlegroups.com, Dr. Roman Grothausmann
Hi JP

I've finally been able to track this down and I am working on a fix. I don't think earlier versions support >4GB images either on Windows. Will let you know when I have something that works.

Thanks
Paul

--
You received this message because you are subscribed to the Google Groups "itksnap-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to itksnap-users+unsubscribe@googlegroups.com.
To post to this group, send email to itksna...@googlegroups.com.
Visit this group at https://groups.google.com/group/itksnap-users.

For more options, visit https://groups.google.com/d/optout.



--

Paul Yushkevich

unread,
Mar 29, 2017, 9:45:07 AM3/29/17
to itksna...@googlegroups.com, itksn...@googlegroups.com, Dr. Roman Grothausmann
Hi JP,

The fix was fairly simple - we have to set the following flag when building ITK on Windows 64bit systems:

ITK_USE_64BITS_IDS:BOOL=TRUE

Please try this binary and let me know if it works with large images


Thanks!
Paul

schnjph

unread,
Apr 20, 2017, 7:08:47 AM4/20/17
to itksnap-users, itksn...@googlegroups.com, grothausm...@mh-hannover.de
Dear Paul,

thank you very much. Unfortunately it still does not work (I have tried the file from your link). However, the loading process lasts longer now, but at the end it still crashes. It seems that the program crashes exactly in the moment when the program wants to display the image. I tried .analyze and .mha. Do you have any idea?

Kind regards, JP




Am Mittwoch, 29. März 2017 15:45:07 UTC+2 schrieb Paul Yushkevich:
Hi JP,

The fix was fairly simple - we have to set the following flag when building ITK on Windows 64bit systems:

ITK_USE_64BITS_IDS:BOOL=TRUE

Please try this binary and let me know if it works with large images


Thanks!
Paul
On Wed, Mar 29, 2017 at 5:19 AM, Paul Yushkevich <pyush...@gmail.com> wrote:
Hi JP

I've finally been able to track this down and I am working on a fix. I don't think earlier versions support >4GB images either on Windows. Will let you know when I have something that works.

Thanks
Paul
On Mon, Mar 20, 2017 at 1:12 PM, schnjph <sch...@gmail.com> wrote:
Dear all,

in the current version 3.6.0-rc1, ITK snap still crashes when I open large datasets. Is there a solution in the current version? Or should I downgrade to 3.4?
For details, please see my topic "large datasets".

Kind regards and thank you very much in advance.

JP

--
You received this message because you are subscribed to the Google Groups "itksnap-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to itksnap-user...@googlegroups.com.

To post to this group, send email to itksna...@googlegroups.com.
Visit this group at https://groups.google.com/group/itksnap-users.

For more options, visit https://groups.google.com/d/optout.
--
Paul A. Yushkevich, Ph.D.
Associate Professor
Penn Image Computing and Science Laboratory
Department of Radiology
University of Pennsylvania

schnjph

unread,
May 19, 2017, 7:39:15 AM5/19/17
to itksnap-users, itksn...@googlegroups.com, grothausm...@mh-hannover.de
Dear Paul,

do you have an idea meanwhile? Because otherwise I may have to change the segmentation software?
KR,
JP

Paul Yushkevich

unread,
Jun 1, 2017, 7:10:19 AM6/1/17
to itksna...@googlegroups.com, itksn...@googlegroups.com, Dr. Roman Grothausmann
Could you please send me a dataset that is causing ITK-SNAP to crash? I have created some large files and have had no problems loading them, so it would be helpful to know exactly what data is causing this.

Thanks!
Paul.

To unsubscribe from this group and stop receiving emails from it, send an email to itksnap-users+unsubscribe@googlegroups.com.

To post to this group, send email to itksna...@googlegroups.com.
Visit this group at https://groups.google.com/group/itksnap-users.
For more options, visit https://groups.google.com/d/optout.

Moran LG

unread,
May 19, 2020, 10:02:47 AM5/19/20
to itksnap-users
Dear all,

The error still seems to be present on the new version and the link with the fixed version doesn't lead to a good version. I am trying to open Dicom images of 6 Go. I am unable to build the software myself, is it possible to have a binary with the error fixed please ?

Thanks,
Moran
Reply all
Reply to author
Forward
0 new messages