Thank you very much for your suggestion. I will check it.
Hello everyone,
I'm encountering a GurobiError when running COMPASS (Metabolic analysis software for single-cell data) analysis on my single-cell RNA-seq data. The error occurs during the optimization process, but I've verified that my input data does not contain any NaN or Infinite values.
The package is in
Command Used
compass --data /path/to/my_data.h5ad --num-processes 10 --species homo_sapiens
Error Message
Traceback (most recent call last):
File "/path/to/compass/bin/compass", line 7, in <module>
sys.exit(entry())
File "/path/to/compass/lib/python3.10/site-packages/compass/main.py", line 1438, in entry
runCompassParallel(args)
File "/path/to/compass/lib/python3.10/site-packages/compass/main.py", line 1505, in runCompassParallel
res.get()
File "/path/to/python3.10/multiprocessing/pool.py", line 774, in get
raise self._value
gurobipy._exception.GurobiError: Element 47 of a double array is Nan or Inf.
I have verified that my .h5ad file contains no NaN values in the expression matrix, but I'm unsure how to resolve this error. Any guidance is appreciated!
1 answer
Either something is wrong with program installation, or with your data. In the GitHub repository there are some test files, and I suggest you try them first. If those work, the installation is correct and it must be your data.
Computers generally don't throw these errors for no reasons, so the most likely culprit is still your dataset. You said to have checked for NaN, how about for Inf values? It may help to convert your file to a format that is easier to inspect, and the error tells you exactly where to look. I am not sure whether Element 47 here means row 47 or column 47, but I would check both. Keep in mind that because of python's zero indexing you should be checking the 48th element.
If you share the relevant lines of your data it may be easier to help you.
Log in to answer this question.