Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error running external_dependencies.py file ? #3668

Closed
zhouhao-learning opened this issue Oct 14, 2018 · 6 comments
Closed

Error running external_dependencies.py file ? #3668

zhouhao-learning opened this issue Oct 14, 2018 · 6 comments

Comments

@zhouhao-learning
Copy link

I'm using version 2.1.1 of CellProfiler, and then I want to update the dependencies of CellProfiler, so I executed the python external_dependencies.py-o command, but I got the following error:

Traceback (most recent call last):
  File "CellProfiler/external_dependencies.py", line 145, in fetch_external_dependencies
    fetchfile(path, url)
  File "CellProfiler/external_dependencies.py", line 107, in fetchfile
    src = urllib2.urlopen(url)
  File "/home/zh/anaconda2/lib/python2.7/urllib2.py", line 154, in urlopen
    return opener.open(url, data, timeout)
  File "/home/zh/anaconda2/lib/python2.7/urllib2.py", line 429, in open
    response = self._open(req, data)
  File "/home/zh/anaconda2/lib/python2.7/urllib2.py", line 447, in _open
    '_open', req)
  File "/home/zh/anaconda2/lib/python2.7/urllib2.py", line 407, in _call_chain
    result = func(*args)
  File "/home/zh/anaconda2/lib/python2.7/urllib2.py", line 1336, in file_open
    return self.open_local_file(req)
  File "/home/zh/anaconda2/lib/python2.7/urllib2.py", line 1376, in open_local_file
    raise URLError(msg)
URLError: <urlopen error [Errno 2] No such file or directory: '/CP/dependencies/apache-maven-3.0.4-bin.zip'>
Could not fetch external binary dependency /project/hit_cell/test/process-plate/imagej/apache-maven-3.0.4-bin.zip from file:///CP/dependencies/apache-maven-3.0.4-bin.zip.  Some functionality may be missing.  You might try installing it by hand.

This URL link is invalid. I want to know why? How should I modify it to run correctly?

@zhouhao-learning
Copy link
Author

I successfully modified the URL path problem, but I got a new problem:

Traceback (most recent call last):
  File "CellProfiler/external_dependencies.py", line 177, in fetch_external_dependencies
    aggressive_update = aggressive_update)
  File "CellProfiler/external_dependencies.py", line 270, in run_maven
    subprocess.check_call(args, cwd = pom_path, env=env)
  File "/home/zh/anaconda2/lib/python2.7/subprocess.py", line 190, in check_call
    raise CalledProcessError(retcode, cmd)
CalledProcessError: Command '['/project/hit_cell/test/process-plate/imagej/maven/apache-maven-3.0.4/bin/mvn', '-U', 'clean']' returned non-zero exit status 1
Maven failed to update Java dependencies.
Traceback (most recent call last):
  File "CellProfiler/external_dependencies.py", line 177, in fetch_external_dependencies
    aggressive_update = aggressive_update)
  File "CellProfiler/external_dependencies.py", line 270, in run_maven
    subprocess.check_call(args, cwd = pom_path, env=env)
  File "/home/zh/anaconda2/lib/python2.7/subprocess.py", line 185, in check_call
    retcode = call(*popenargs, **kwargs)
  File "/home/zh/anaconda2/lib/python2.7/subprocess.py", line 172, in call
    return Popen(*popenargs, **kwargs).wait()
  File "/home/zh/anaconda2/lib/python2.7/subprocess.py", line 394, in __init__
    errread, errwrite)
  File "/home/zh/anaconda2/lib/python2.7/subprocess.py", line 1047, in _execute_child
    raise child_exception
OSError: [Errno 2] No such file or directory: '/project/hit_cell/test/process-plate/java'
Maven failed to update Java dependencies.
Fetch complete

What's going on?

@AetherUnbound
Copy link
Collaborator

Hello again, what is the result of running echo $JAVA_HOME?

@zhouhao-learning
Copy link
Author

@AetherUnbound
The result of echo $JAVA_HOME is: /usr/lib/jvm/java-8-oracle

@zhouhao-learning
Copy link
Author

@AetherUnbound
I solved the above mistake, but got another mistake:

Platedir: /project/hit_cell/test/process-plate/ExampleFly/ExampleFly/images
Output: /project/hit_cell/test/process-plate
0 - Generating CSV file
1 - Running Illumination Pipeline
/home/zh/anaconda2/envs/py27/lib/python2.7/site-packages/h5py/__init__.py:36: FutureWarning: Conversion of the second argument of issubdtype from `float` to `np.floating` is deprecated. In future, it will be treated as `np.float64 == np.dtype(float).type`.
  from ._conv import register_converters as _register_converters
Version: 2018-10-12T08:11:28 6c2d896 / 20181012081128
Plugin directory doesn't point to valid folder: /project/hit_cell/test/process-plate/plugins
Uncaught exception in CellProfiler.py
Traceback (most recent call last):
  File "./CellProfiler/CellProfiler.py", line 249, in main
    run_pipeline_headless(options, args)
  File "./CellProfiler/CellProfiler.py", line 787, in run_pipeline_headless
    from cellprofiler.pipeline import Pipeline, EXIT_STATUS, M_PIPELINE
  File "/project/hit_cell/test/process-plate/CellProfiler/cellprofiler/pipeline.py", line 58, in <module>
    from bioformats.omexml import OMEXML
  File "/project/hit_cell/test/process-plate/CellProfiler/bioformats/__init__.py", line 150, in <module>
    start_cellprofiler_jvm()
  File "/project/hit_cell/test/process-plate/CellProfiler/bioformats/__init__.py", line 141, in start_cellprofiler_jvm
    jutil.start_vm(args, run_headless)
  File "/project/hit_cell/test/process-plate/CellProfiler/cellprofiler/utilities/jutil.py", line 233, in start_vm
    if javabridge.get_vm().is_active():
AttributeError: 'module' object has no attribute 'get_vm'
Failed to stop Ilastik
Failed to stop the JVM
2 - Running Analysis Pipeline
/home/zh/anaconda2/envs/py27/lib/python2.7/site-packages/h5py/__init__.py:36: FutureWarning: Conversion of the second argument of issubdtype from `float` to `np.floating` is deprecated. In future, it will be treated as `np.float64 == np.dtype(float).type`.
  from ._conv import register_converters as _register_converters
Version: 2018-10-12T08:11:28 6c2d896 / 20181012081128
Plugin directory doesn't point to valid folder: /project/hit_cell/test/process-plate/plugins
Uncaught exception in CellProfiler.py
Traceback (most recent call last):
  File "./CellProfiler/CellProfiler.py", line 249, in main
    run_pipeline_headless(options, args)
  File "./CellProfiler/CellProfiler.py", line 787, in run_pipeline_headless
    from cellprofiler.pipeline import Pipeline, EXIT_STATUS, M_PIPELINE
  File "/project/hit_cell/test/process-plate/CellProfiler/cellprofiler/pipeline.py", line 58, in <module>
    from bioformats.omexml import OMEXML
  File "/project/hit_cell/test/process-plate/CellProfiler/bioformats/__init__.py", line 150, in <module>
    start_cellprofiler_jvm()
  File "/project/hit_cell/test/process-plate/CellProfiler/bioformats/__init__.py", line 141, in start_cellprofiler_jvm
    jutil.start_vm(args, run_headless)
  File "/project/hit_cell/test/process-plate/CellProfiler/cellprofiler/utilities/jutil.py", line 233, in start_vm
    if javabridge.get_vm().is_active():
AttributeError: 'module' object has no attribute 'get_vm'
Failed to stop Ilastik
Failed to stop the JVM
>>>>>> creating cache files
/home/zh/anaconda2/envs/py27/bin/python: No module named cpa.profiling

My javabridge version is 1.0.18, which is my javabridge version, isn't it? What's the matter? How should I continue?

@AetherUnbound
Copy link
Collaborator

AetherUnbound commented Oct 16, 2018

My javabridge version is 1.0.18, which is my javabridge version, isn't it?

Yes, your javabridge version is your javabridge version, but if you're running 2.1.1 then you will be using the javabridge that was bundled with cellprofiler at that time: https://github.com/CellProfiler/CellProfiler/blob/2.1.1/cellprofiler/utilities/javabridge.pyx. This file may need to be compiled, I'm not sure if the external_dependencies file takes care of that.

I might try running cython /project/hit_cell/test/process-plate/CellProfiler/cellprofiler/utilities/javabridge.pyx to see if it can compile the module.

@AetherUnbound
Copy link
Collaborator

Closing this - feel free to reopen if this issue still persists.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants