[ITK-users] Big tiff file

Lowekamp, Bradley (NIH/NLM/LHC) [C] blowekamp at mail.nih.gov
Mon Oct 23 09:15:51 EDT 2017


Hello,

You have correctly figured this out. Technically the regular tiff format can support up to 4GB, but  in ITK we made the determination to switch to the BigTiff format at 2GB [1]. This is does to ensure that we can properly do signed integer arithmetic for the file format.

I have also used ImageJ/FIJI and a program call IMOD [2] (another electron microscopy viewer) for viewing these big tiff files.

HTH,
Brad

[1] https://github.com/InsightSoftwareConsortium/ITK/blob/4456e0431b0d35f55eb1eadc5ca8a7c3fe2c8af9/Modules/IO/TIFF/src/itkTIFFImageIO.cxx#L595
[2] http://bio3d.colorado.edu/imod/

On 10/21/17, 8:40 PM, "Gib Bogle" <g.bogle at auckland.ac.nz> wrote:

    I've managed to find the answer to one of my questions, by looking at the file header values.  A TIFF file less than 2GB has these 4 header bytes:
    49 49 2A 00
    and over 2GB (BigTIFF) has
    49 49 2B 00
    ITK handles this automatically.
    
    I can view the big TIFFs with Fiji (ImageJ), so this is not a bad option for displaying the slices.  What I like about Irfanview is that it's very light-weight.  ImageJ loads the whole file into memory, which can take some time, while Irfanview loads one slice at a time.
    
    I am not keen about Slicer - it is a real heavy-weight - and Tomviz is very specialised, designed for viewing tomography data, i.e. images in a tilt series.
    ________________________________________
    From: Matt McCormick <matt.mccormick at kitware.com>
    Sent: Sunday, 22 October 2017 4:48 a.m.
    To: Dženan Zukić
    Cc: Gib Bogle; Insight-users
    Subject: Re: [ITK-users] Big tiff file
    
    Hi,
    
    Since ITKv4, support for "BigTiff" was added, so ITK can support TIFF
    files larger than 4GB.
    
    One possible limitation may be the filesystem -- avoid FAT32 formatted
    filesystem that will run into size limits.
    
    The file could be viewed with a number of ITK-supported viewers, e.g.
    
    - 3D-Slicer: https://www.slicer.org/
    - ITK-SNAP: http://www.itksnap.org/
    - Tomviz: http://www.tomviz.org/
    
    HTH,
    Matt
    
    On Sat, Oct 21, 2017 at 11:40 AM, Dženan Zukić <dzenanz at gmail.com> wrote:
    > Hi Gib,
    >
    > TIFF is limited to 4GiB. Unless you must use TIFF, better switch to
    > MetaImage or NRRD.
    >
    > Regards,
    > Dženan
    >
    > On Sat, Oct 21, 2017 at 12:08 AM, Gib Bogle <g.bogle at auckland.ac.nz> wrote:
    >>
    >> Hi,
    >>
    >>
    >> I am joining a stack of 2D tiffs into a 3D tiff, and have run into a
    >> problem with big files.  When the uncompressed size of the 3D file is more
    >> than 2GB I get an error when I try to view it with Irfanview.  At first I
    >> thought maybe I needed to upgrade from ITK4.8.0, but after installing and
    >> using ITK4.12.2 I see that I have the same issue.  Irfanview says:
    >>
    >> "Invalid or unsupported TIF file"
    >>
    >> I now suspect that the problem is not ITK-related, rather it is a
    >> limitation of Irfanview.
    >>
    >> I have two questions:
    >>
    >>
    >> Is there a limit on the allowed size of a tiff file?
    >>
    >> Is there another program (preferably free) that can open for viewing tiff
    >> files bigger than 2GB?
    >>
    >>
    >> It is useful but not essential for me to be able to view these big 3D
    >> files.  I will use ITK functions to process the 3D files, and I'm assuming
    >> that any file that ITK can create it can also read.
    >>
    >>
    >> Thanks
    >>
    >> Gib
    >>
    >>
    >> The ITK community is transitioning from this mailing list to
    >> discourse.itk.org. Please join us there!
    >> ________________________________
    >> Powered by www.kitware.com
    >>
    >> Visit other Kitware open-source projects at
    >> http://www.kitware.com/opensource/opensource.html
    >>
    >> Kitware offers ITK Training Courses, for more information visit:
    >> http://www.kitware.com/products/protraining.php
    >>
    >> Please keep messages on-topic and check the ITK FAQ at:
    >> http://www.itk.org/Wiki/ITK_FAQ
    >>
    >> Follow this link to subscribe/unsubscribe:
    >> http://public.kitware.com/mailman/listinfo/insight-users
    >>
    >
    >
    > The ITK community is transitioning from this mailing list to
    > discourse.itk.org. Please join us there!
    > ________________________________
    > Powered by www.kitware.com
    >
    > Visit other Kitware open-source projects at
    > http://www.kitware.com/opensource/opensource.html
    >
    > Kitware offers ITK Training Courses, for more information visit:
    > http://www.kitware.com/products/protraining.php
    >
    > Please keep messages on-topic and check the ITK FAQ at:
    > http://www.itk.org/Wiki/ITK_FAQ
    >
    > Follow this link to subscribe/unsubscribe:
    > http://public.kitware.com/mailman/listinfo/insight-users
    >
    The ITK community is transitioning from this mailing list to discourse.itk.org. Please join us there!
    ________________________________
    Powered by www.kitware.com
    
    Visit other Kitware open-source projects at
    http://www.kitware.com/opensource/opensource.html
    
    Kitware offers ITK Training Courses, for more information visit:
    http://www.kitware.com/products/protraining.php
    
    Please keep messages on-topic and check the ITK FAQ at:
    http://www.itk.org/Wiki/ITK_FAQ
    
    Follow this link to subscribe/unsubscribe:
    http://public.kitware.com/mailman/listinfo/insight-users
    



More information about the Insight-users mailing list