Hi. I am very unfamiliar with python still, and just wanted to try out muon
to compare the integration method with what I’ve achieved in R’s Harmony
. I get an error when running sc.pp.neighbours
:
>>> sc.pp.neighbors(rna, n_neighbors=10, n_pcs=20)
Traceback (most recent call last):
File "/home/user/lib/python3.8/multiprocessing/synchronize.py", line 28, in <module>
from _multiprocessing import SemLock, sem_unlink
ImportError: cannot import name 'SemLock' from '_multiprocessing' (unknown location)
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/user/lib/python3.8/site-packages/numba/core/errors.py", line 823, in new_error_context
yield
File "/home/user/lib/python3.8/site-packages/numba/core/lowering.py", line 285, in lower_block
self.lower_inst(inst)
File "/home/user/lib/python3.8/site-packages/numba/parfors/parfor_lowering.py", line 51, in lower_inst
_lower_parfor_parallel(self, inst)
File "/home/user/lib/python3.8/site-packages/numba/parfors/parfor_lowering.py", line 58, in _lower_parfor_parallel
return _lower_parfor_parallel_std(lowerer, parfor)
File "/home/user/lib/python3.8/site-packages/numba/parfors/parfor_lowering.py", line 372, in _lower_parfor_parallel_std
call_parallel_gufunc(
File "/home/user/lib/python3.8/site-packages/numba/parfors/parfor_lowering.py", line 1632, in call_parallel_gufunc
_launch_threads()
File "/home/user/lib/python3.8/site-packages/numba/np/ufunc/parallel.py", line 381, in _launch_threads
_set_init_process_lock()
File "/home/user/lib/python3.8/site-packages/numba/np/ufunc/parallel.py", line 309, in _set_init_process_lock
_backend_init_process_lock = ctx.RLock()
File "/home/user/lib/python3.8/multiprocessing/context.py", line 72, in RLock
from .synchronize import RLock
File "/home/user/lib/python3.8/multiprocessing/synchronize.py", line 30, in <module>
raise ImportError("This platform lacks a functioning sem_open" +
ImportError: This platform lacks a functioning sem_open implementation, therefore, the required synchronization primitives needed will not function, see issue 3770.
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/home/user/lib/python3.8/site-packages/scanpy/neighbors/__init__.py", line 139, in neighbors
neighbors.compute_neighbors(
File "/home/user/lib/python3.8/site-packages/scanpy/neighbors/__init__.py", line 811, in compute_neighbors
self._distances, self._connectivities = _compute_connectivities_umap(
File "/home/user/lib/python3.8/site-packages/scanpy/neighbors/__init__.py", line 395, in _compute_connectivities_umap
connectivities = fuzzy_simplicial_set(
File "/home/user/lib/python3.8/site-packages/umap/umap_.py", line 581, in fuzzy_simplicial_set
rows, cols, vals, dists = compute_membership_strengths(
File "/home/user/lib/python3.8/site-packages/numba/core/dispatcher.py", line 487, in _compile_for_args
raise e
File "/home/user/lib/python3.8/site-packages/numba/core/dispatcher.py", line 420, in _compile_for_args
return_val = self.compile(tuple(argtypes))
File "/home/user/lib/python3.8/site-packages/numba/core/dispatcher.py", line 965, in compile
cres = self._compiler.compile(args, return_type)
File "/home/user/lib/python3.8/site-packages/numba/core/dispatcher.py", line 125, in compile
status, retval = self._compile_cached(args, return_type)
File "/home/user/lib/python3.8/site-packages/numba/core/dispatcher.py", line 139, in _compile_cached
retval = self._compile_core(args, return_type)
File "/home/user/lib/python3.8/site-packages/numba/core/dispatcher.py", line 152, in _compile_core
cres = compiler.compile_extra(self.targetdescr.typing_context,
File "/home/user/lib/python3.8/site-packages/numba/core/compiler.py", line 762, in compile_extra
return pipeline.compile_extra(func)
File "/home/user/lib/python3.8/site-packages/numba/core/compiler.py", line 460, in compile_extra
return self._compile_bytecode()
File "/home/user/lib/python3.8/site-packages/numba/core/compiler.py", line 528, in _compile_bytecode
return self._compile_core()
File "/home/user/lib/python3.8/site-packages/numba/core/compiler.py", line 507, in _compile_core
raise e
File "/home/user/lib/python3.8/site-packages/numba/core/compiler.py", line 494, in _compile_core
pm.run(self.state)
File "/home/user/lib/python3.8/site-packages/numba/core/compiler_machinery.py", line 368, in run
raise patched_exception
File "/home/user/lib/python3.8/site-packages/numba/core/compiler_machinery.py", line 356, in run
self._runPass(idx, pass_inst, state)
File "/home/user/lib/python3.8/site-packages/numba/core/compiler_lock.py", line 35, in _acquire_compile_lock
return func(*args, **kwargs)
File "/home/user/lib/python3.8/site-packages/numba/core/compiler_machinery.py", line 311, in _runPass
mutated |= check(pss.run_pass, internal_state)
File "/home/user/lib/python3.8/site-packages/numba/core/compiler_machinery.py", line 273, in check
mangled = func(compiler_state)
File "/home/user/lib/python3.8/site-packages/numba/core/typed_passes.py", line 466, in run_pass
lower.lower()
File "/home/user/lib/python3.8/site-packages/numba/core/lowering.py", line 187, in lower
self.lower_normal_function(self.fndesc)
File "/home/user/lib/python3.8/site-packages/numba/core/lowering.py", line 241, in lower_normal_function
entry_block_tail = self.lower_function_body()
File "/home/user/lib/python3.8/site-packages/numba/core/lowering.py", line 271, in lower_function_body
self.lower_block(block)
File "/home/user/lib/python3.8/site-packages/numba/core/lowering.py", line 285, in lower_block
self.lower_inst(inst)
File "/home/user/lib/python3.8/contextlib.py", line 131, in __exit__
self.gen.throw(type, value, traceback)
File "/home/user/lib/python3.8/site-packages/numba/core/errors.py", line 837, in new_error_context
raise newerr.with_traceback(tb)
numba.core.errors.LoweringError: Failed in nopython mode pipeline (step: native parfor lowering)
This platform lacks a functioning sem_open implementation, therefore, the required synchronization primitives needed will not function, see issue 3770.
File "../../../../../../../../home/user/lib/python3.8/site-packages/umap/umap_.py", line 410:
def compute_membership_strengths(
<source elided>
rows = np.zeros(knn_indices.size, dtype=np.int32)
^
During: lowering "id=8[LoopNest(index_variable = parfor_index.329, range = (0, $28load_attr.11, 1))]{447: <ir.Block at /home/user/lib/python3.8/site-packages/umap/umap_.py (410)>}Var(parfor_index.329, umap_.py:410)" at /home/user/lib/python3.8/site-packages/umap/umap_.py (410)
As best I can make out, this means something goes wrong package wise with umap_.py
? Or is there some error in my data? I am running and installing everything from my campus server in a conda environ. So far everything runs smoothly upstream of this function when I follow the muon
tutorial.
Since I am really new to python, please be very specific in what info you require if more is needed to troubleshoot this issue.
Thanks for any help.