NOTICE! This is a static HTML version of a legacy Fiji BugZilla bug.

The Fiji project now uses GitHub Issues for issue tracking.

Please file all new issues there.

Bug 991 - Slow loading of image sequence
Slow loading of image sequence
Status: RESOLVED FIXED
Product: Fiji
Classification: Unclassified
Component: Plugins
unspecified
PC Windows
: P4 normal
Assigned To: ImageJ Bugs Mailing List
Depends on:
Blocks:
 
Reported: 2015-01-22 14:53 CST by Bruno Afonso
Modified: 2015-02-17 07:26 CST
2 users (show)

See Also:

Description Bruno Afonso 2015-01-22 14:53:45 CST
Loading up image sequences is awfully slow. This is not a hardware limitation. I can write data to this drive likely 100 fold than I can read with Fiji/ImageJ.

Information about your version of Java:

  os.arch => amd64
  os.name => Windows 7
  os.version => 6.1
  java.version => 1.6.0_24
  java.vendor => Sun Microsystems Inc.
  java.runtime.name => Java(TM) SE Runtime Environment
  java.runtime.version => 1.6.0_24-b07
  java.vm.name => Java HotSpot(TM) 64-Bit Server VM
  java.vm.version => 19.1-b02
  java.vm.vendor => Sun Microsystems Inc.
  java.vm.info => mixed mode
  java.awt.graphicsenv => sun.awt.Win32GraphicsEnvironment
  java.specification.name => Java Platform API Specification
  java.specification.version => 1.6
  sun.cpu.endian => little
  sun.desktop => windows
  file.separator => \

The up-to-date check says: REMIND_LATER

Information relevant to JAVA_HOME related problems:

  JAVA_HOME is set to: C:\Users\labadmin\Desktop\Fiji.app/java/win64/jdk1.6.0_24//jre
  imagej.dir => C:\Users\labadmin\Desktop\Fiji.app

Information about the version of each plugin:

Activated update sites:
ImageJ: http://update.imagej.net/ (last check:20150122054514)
Fiji: http://fiji.sc/update/ (last check:20150122040708)

Files not up-to-date:
  8c636e50 (OBSOLETE_UNINSTALLED) 20150109065224 jars/jai_codec.jar
  717dd8e0 (OBSOLETE_UNINSTALLED) 20150109065224 jars/jai_core.jar
  1ad3be0d (LOCAL_ONLY) 20150109065226 jars/jpedalSTD.jar
Comment 1 Bruno Afonso 2015-01-22 14:55:52 CST
These are non compressed tiff files, 16bit. I've also tried the new imageJ2 scientific importer and it appears to be even slower. Files consist of a single tiff file saved with opencv's imwrite functionality.
Comment 2 Curtis Rueden 2015-01-23 08:19:32 CST
Can you please post a sample image somewhere online?
Comment 4 Curtis Rueden 2015-02-04 16:43:08 CST
On my OS X 10.10 system, I can import that data in less than 5 seconds using File > Import > Image Sequence.

> I've also tried the new imageJ2 scientific importer
> and it appears to be even slower.

Based on this comment, I assume you are experiencing slow import even though "Use SCIFIO when opening files" under Edit > Options > ImageJ2 is disabled?

And if I understand correctly, when you enable it, the import is even slower?

As an aside, we are in the process of actively improving SCIFIO performance. But the import should be fast right now with that option disabled.

When you say "awfully slow," what sort of performance are you seeing?

Lastly, have you checked whether File > Import > Bio-Formats with "Group files with similar names" enabled is any better?
Comment 5 Bruno Afonso 2015-02-16 21:53:56 CST
The issue appears to be that openCV saves TIFF files with LZW compression. This makes loading files in ImageJ/Fiji incredibly slow compared to non-compressed tiff files. I can only speculate, but it seems to me that one could optimize loading compressed files. '

I just ended up writing my own tiff writer..

Thanks for looking into this.
Comment 6 Curtis Rueden 2015-02-17 07:26:27 CST
Improvements to the performance of SCIFIO's LZW support would be most welcome, and would benefit the entire community. Please see:

https://github.com/scifio/scifio#contributing-to-scifio

https://github.com/scifio/scifio/blob/scifio-0.21.0/src/main/java/io/scif/codec/LZWCodec.java#L42