CellProfiler Batch problems



I am running CP 2.1 on our computing cluster and for the most part I am having no problems. However, I have one set of images which are giving me an error (these images have 32 series per image rather than \8).

I can create the batch file without any problem. When I go to run the batch file, the first set works absolutely fine.

However, any sets starting after the first gives an error which appears to be related to its ability to find the path of the file (I seem to get the ilastik error even when it runs correctly).

Version: 2014-06-13T13:02:53 / 20140613130253
Plugin directory doesn't point to valid folder: /home/fraserlab/adrian/RunCP/plugins
ilastik import: failed to import the ilastik. Please follow the instructions on 
                          "http://www.ilastik.org" to install ilastik
Traceback (most recent call last):
  File "/usr/cellprofiler/src/CellProfiler/cellprofiler/modules/ilastik_pixel_classification.py", line 81, in <module>
    import ilastik_main
ImportError: No module named ilastik_main
Times reported are CPU times for each module, not wall-clock time
Error detected during run of module LoadImages
Traceback (most recent call last):
  File "/usr/cellprofiler/src/CellProfiler/cellprofiler/pipeline.py", line 1787, in run_with_yield
  File "/usr/cellprofiler/src/CellProfiler/cellprofiler/modules/loadimages.py", line 2143, in run
    full_name = url2pathname(url.encode('utf-8'))
AttributeError: 'NoneType' object has no attribute 'encode'
Mon Jun 16 11:20:50 2014: Image # 97, module LoadImages # 1: 0.00 sec
stopping worker thread  0
stopping worker thread  1
stopping worker thread  2
stopping worker thread  3
stopping worker thread  4
stopping worker thread  5
stopping worker thread  6
stopping worker thread  7
stopping worker thread  8
Exiting the JVM monitor thread



The ilastik error can be ignored (more here, if you care).

What version of CellProfiler are you running?

Some users had reported awhile ago that the ‘-l’ switch wasn’t working. We thought we may have fixed the problem some months ago, but perhaps not?
The workaround was to use the Metadata and Groups modules rather than the ‘-f’ and ‘-l’ switches at all.

Also, does your cluster have access to the directory of your images? Likely yes, since you say it works on others, but the error

[quote] full_name = url2pathname(url.encode(‘utf-8’))
AttributeError: ‘NoneType’ object has no attribute ‘encode’

implies that CreateBatchFiles or whatever you may use to translate your paths to your cluster’s naming scheme might not be working. Perhaps this is actually the ‘-l’ switch issue though, not sure.



Thanks for the reply David.

I’m not positive which version I’m using aside from what the program spits out (Version: 2014-06-13T13:02:53 / 20140613130253). I know our sys admin had upgraded to one of the newer versions, but I’m not positive if we’re at a version where that bug is fixed. I tried a bit to use MetaData and Groups but couldn’t really sort it out.

What I decided to do in the end was to go back to using CP 2.0, which works absolutely fine for me. I’ll admit the error I’m getting is quite peculiar and it only really manifests itself with one set of images.


Fair enough! I’m happy at least that 2.0 still works for you.

If you do find any traceable oddity to your troublesome image set, let us know (any special characters in the file or path name? etc.). Hopefully we could then find any issue with CP.