[ome-devel] calling getImageCount or getPlaneCount from matlab returns wrong values

Josh Moore josh at glencoesoftware.com
Mon Jan 23 08:27:23 GMT 2012


Replied to by Curtis on the ImageJ list: http://comments.gmane.org/gmane.comp.java.imagej/23522

> I know it's been awhile since this thread, but I wanted to clarify that
> Bio-Formats does support parsing of variable time stamps, converted from any
> supported format. And as Janne suggests, there are some examples that
> demonstrate how to do it.
> 
> For an ImageJ macro, see planeTimings.txt, linked from:
>   
> http://loci.wisc.edu/bio-formats/imagej
> 
> 
> For Java code, see PrintTimestamps.java, linked from:
>   
> http://loci.wisc.edu/bio-formats/bio-formats-java-library
> 
> 
> HTH,
> Curtis

Cheers,
~Josh


On Jan 21, 2012, at 7:40 PM, Heinrich Grabmayr wrote:

> Hello everyone,
> 
> 
> 
> I just tried to get the total number of planes in an image in matlab.
> 
> So I opened the file using bfopen.m from the loci website and get the image
> cell; metadata is stored in the second entry, so trying r = bfopen(..); meta
> = r{2}; a = meta.getImageCount() b = meta.getPlaneCount(0)
> 
> 
> 
> returns a==b==0.
> 
> However, running the command line script  showinf with the same versions of
> loci_tools and bio_formats (4.3.3), the correct value is given in line 475:
> 
> int imageCount = reader.getImageCount();
> 
> Also, when I query
> 
> getPixelsSizeT(0)
> 
> getPixelsSizeC(0)
> 
> in matlab, the correct values are returned, and all the rest of metadata not
> concerned with planes is returned correctly.
> 
> meta.getPlaneDeltaT(0,0)
> 
> returns empy.
> 
> 
> 
> I cannot think of any reason for this but the initialization of metadata in
> bfopen might be different than that in showinf? But then, why should
> querying it work with anything but planes?
> 
> 
> 
> Does any of you have an idea about that?
> 
> 
> 
> Cheers
> 
> --Heinrich
> 



More information about the ome-devel mailing list