We're Hiring!

Trouble with Matlab parfor for Bioformats

General and open developer discussion about using OMERO APIs from C++, Java, Python, Matlab and more! Please new questions at https://forum.image.sc/tags/omero
Please note:
Historical discussions about OMERO. Please look for and ask new questions at https://forum.image.sc/tags/omero

If you are having trouble with custom code, please provide a link to a public repository, ideally GitHub.

Trouble with Matlab parfor for Bioformats

Postby nhuebsch » Sat Jan 28, 2017 2:24 am

I saw someone else had a problem incorporating Bioformats functions with parfor loops in Matlab. Not sure if this is solveable but I hope so (I also posted on another part of the forum by mistake but I think this is the correct place). I am running a code that processes stacks two images at a time to look at movements. I can use parfor loops if I first load the entire stack of images into ram with bfGetplane. However, if I try to use bfGetplane within a parfor loop, I get this error:

Error using bfGetPlane (line 49)
The value of 'r' is invalid. It must satisfy the function: @(x)isa(x,'loci.formats.IFormatReader')&&~isempty(x.getCurrentFile()).

when the command is : " I = bfGetPlane(reader,i)" (i) = the "ith" plane.

Is there a solution to this issue, or can you recommend a work-around that doesn't involve keeping the entire image series in active RAM?

thanks.
nhuebsch
 
Posts: 7
Joined: Mon Dec 05, 2016 6:31 pm

Re: Trouble with Matlab parfor for Bioformats

Postby sbesson » Sun Jan 29, 2017 1:46 pm

User avatar
sbesson
Team Member
 
Posts: 421
Joined: Tue Feb 28, 2012 7:20 pm


Return to Developer Discussion

Who is online

Users browsing this forum: No registered users and 0 guests