scib: Error in LISI metric
I had the following error occur when calculating the LISI metric:
Convert nearest neighbor matrix and distances for LISI.
Compute knn on shortest paths
LISI score estimation
12 processes started.
/Users/luke.zappia/miniconda3/envs/scIB-python/lib/python3.7/site-packages/anndata/_core/anndata.py:21: FutureWarning: pandas.core.index is deprecated and will be removed in a future version. The public classes are available in the top-level namespace.
from pandas.core.index import RangeIndex
Trying to set attribute `.obs` of view, copying.
Trying to set attribute `.obs` of view, copying.
Trying to set attribute `.obs` of view, copying.
Trying to set attribute `.obs` of view, copying.
malformed matrix line 83 2661 9.753568422904793e-309
multiprocessing.pool.RemoteTraceback:
"""
Traceback (most recent call last):
File "/Users/luke.zappia/miniconda3/envs/scIB-python/lib/python3.7/multiprocessing/pool.py", line 121, in worker
result = (True, func(*args, **kwds))
File "/Users/luke.zappia/miniconda3/envs/scIB-python/lib/python3.7/multiprocessing/pool.py", line 47, in starmapstar
return list(itertools.starmap(args[0], args[1]))
File "/Users/luke.zappia/miniconda3/envs/scIB-python/lib/python3.7/site-packages/scIB/metrics.py", line 1259, in compute_simpson_index_graph
if stat(input_path + '_indices_'+ str(chunk_no) + '.txt').st_size == 0:
FileNotFoundError: [Errno 2] No such file or directory: '/tmp/lisi_tmp1601377709/_indices_1.txt'
"""
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "scripts/metrics.py", line 242, in <module>
trajectory_=trajectory_
File "/Users/luke.zappia/miniconda3/envs/scIB-python/lib/python3.7/site-packages/scIB/metrics.py", line 1876, in metrics
multiprocessing = True, verbose=verbose)
File "/Users/luke.zappia/miniconda3/envs/scIB-python/lib/python3.7/site-packages/scIB/metrics.py", line 1501, in lisi_graph
multiprocessing = multiprocessing, nodes = nodes, verbose=verbose)
File "/Users/luke.zappia/miniconda3/envs/scIB-python/lib/python3.7/site-packages/scIB/metrics.py", line 1434, in lisi_graph_py
count))
File "/Users/luke.zappia/miniconda3/envs/scIB-python/lib/python3.7/multiprocessing/pool.py", line 276, in starmap
return self._map_async(func, iterable, starmapstar, chunksize).get()
File "/Users/luke.zappia/miniconda3/envs/scIB-python/lib/python3.7/multiprocessing/pool.py", line 657, in get
raise self._value
FileNotFoundError: [Errno 2] No such file or directory: '/tmp/lisi_tmp1601377709/_indices_1.txt'
It only happens for one method (scanorama full) so it’s not a general problem but I’m guessing something to do with the integration output.
About this issue
- Original URL
- State: closed
- Created 4 years ago
- Comments: 60 (38 by maintainers)
I would presume that the
cpprun failed due to themalformed matrix lineerror and therefore produced no output (if it’s just a single job where 1 error means no files are generated), which meant the error arose that no input file was available to read to further the calculations. But of course… I have no idea here 😄