[ome-devel] ScanR importer and well labels

Rubén Muñoz ruben.munoz at embl.de
Mon Jan 30 15:00:10 GMT 2012


Dear Melissa, how are you?

Using ScanR importer I found a more recent problem. The dataset I use has labels at the beginning off the file names (A1, A2, A3, ..., A10, A11, A12, B1, ...)

I believe that your code sorts the images alphabetically at some point: (A1, A10, A11, A12, A2, ...)

Please note that the following loop didn't work for that dataset. It expects the images to be in a different order, as it remembers the lastListIndex for the next cycle, assuming always increasing well index. 

386	            for (int c=0; c<nChannels; c++) {
387	              for (int i=lastListIndex; i<list.length; i++) {
388	                String file = list[i];
389	                if (file.indexOf(wellPos) != -1 && file.indexOf(zPos) != -1 &&
390	                  file.indexOf(posPos) != -1 && file.indexOf(tPos) != -1 &&
391	                  file.indexOf(channelNames.get(c)) != -1)
392	                {
393	                  tiffs[next++] = new Location(dir, file).getAbsolutePath();
394	                  if (c == nChannels - 1) {
395	                    lastListIndex = i;
396	                  }
397	                  break;
398	                }
399	              }
400	            }


Back in 4.1 the code was inefficient but worked fine in terms of construction of the tiff list. 


309	            for (int c=0; c<nChannels; c++) {
310	              for (String file : list) {
311	                if (file.indexOf(wellPos) != -1 && file.indexOf(zPos) != -1 &&
312	                  file.indexOf(posPos) != -1 && file.indexOf(tPos) != -1 &&
313	                  file.indexOf(channelNames.get(c)) != -1)
314	                {
315	                  tiffs[next++] = new Location(dir, file).getAbsolutePath();
316	                  break;
317	                }
318	              }
319	            }

I have temporally fixed our copy using the upper loop, which is still inefficient for large datasets, it would be interesting to have a quicker importer though. 

Thaanks and best regards,

Rubén Muñoz
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openmicroscopy.org.uk/pipermail/ome-devel/attachments/20120130/94ed5859/attachment-0001.html>


More information about the ome-devel mailing list