[ome-devel] using LabView to write ome-tiff? with java4cpp?

Curtis Rueden ctrueden at wisc.edu
Thu Mar 19 20:58:42 GMT 2015


Hi Heinrich,

> I am currently developing a microscope that is controlled by a LabView
> program and generates a massive amount of data output. As I like
> ome-tiff, I'd like to save my images in that format.

Your major options are:

1) Wait for the native Bio-Formats C++ implementation [1], slated for OME
version 5.1 (and subject to change until 5.2).
 - Pro: No more need for Java on the acquisition machine!
 - Con: Non-trivial to build and deploy due to required dependencies.
 - Con: Not actually ready yet. ;-)

2) Use the Bio-Formats C++ bindings [2], available now.
 - Pro: Provides access to the entire Bio-Formats API.
 - Con: Non-trivial to build and deploy due to required dependencies.

3) Use an interprocess solution such as:
 - Subimager [3] -- used by CellProfiler
 - A pipes-based bridge [4] -- used by ITK
 - Pro: As fast as in-process solutions, with fewer dependencies.
 - Con: Requires some coding to conform to your project's requirements.

4) Write TIFF using libtiff, injecting your own OME-XML at the end. General
approach:

- Write a stub ImageDescription comment (four chars or less; e.g., "xx")
using libtiff.

- Generate your own OME-XML, maybe using a C++ XML library of your choice.

- Inject the XML string by appending it to the TIFF (fast), then seeking to
the ImageDescription offset and length fields of the TIFF and updating them
accordingly (also fast).

- This approach avoids needing to rewrite the entire TIFF file just to add
OME-XML later. This is how we do it in WiscScan, although we do use the
Bio-Formats C++ bindings (see option 2 above) for actually building the
OME-XML string itself using the Bio-Formats MetadataStore API.

Further reading:
http://loci.wisc.edu/software/interfacing-non-java-code

Regards,
Curtis

[1]
http://openmicroscopy.org/site/support/bio-formats5.1/developers/cpp.html
[2]
http://openmicroscopy.org/site/support/bio-formats5.0/developers/c-bindings.html
[3] https://github.com/CellProfiler/subimager
[4] https://github.com/scifio/scifio-itk-bridge

On Thu, Mar 19, 2015 at 3:42 PM, Grabmayr, Heinrich <
Heinrich.Grabmayr at ph.tum.de> wrote:

> Hi everyone,
>
> I am currently developing a microscope that is controlled by a LabView
> program and generates a massive amount of data output. As I like ome-tiff,
> I'd like to save my images in that format. Now, while LabView can easily
> talk to .dlls, java libraries are harder to implement. I was in a similar
> situation before, and back then, I used libtiff to write files that comply
> with ome-tiff (2010 schema). As I am not a software engineer, the solution
> turned out to work for me (with low data rates) but is not nice and
> probably far from efficient.
> Now with these more stringent requirements, I would be interested in a
> better solution. Might anyone have run into the same situation and come up
> with something good?
> When looking around the loci website, I found mention of i3dcore, and that
> it uses java4cpp to wrap the library. Do you know about how this performs?
> Or do you know any other solution, maybe not ome-tiff after all?
> To be more specific, in one type of experiment I want to do, I'll acquire
> 30GB of images into RAM in 10 min and want to then save this to files.
>
> Thanks
>    Heinrich
> _______________________________________________
> ome-devel mailing list
> ome-devel at lists.openmicroscopy.org.uk
> http://lists.openmicroscopy.org.uk/mailman/listinfo/ome-devel
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openmicroscopy.org.uk/pipermail/ome-devel/attachments/20150319/d0c3674e/attachment.html>


More information about the ome-devel mailing list