You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have checked that this issue has not already been reported.
I have confirmed this bug exists on the latest version of scanpy.
(optional) I have confirmed this bug exists on the main branch of scanpy.
What happened?
When we tried to compute QC metrics for our dataset we got this error (see title). Produced by the X.eliminate_zeros() call.
We also traced the error back to genes that have only zeros in them, which would remove these columns and thus change the shape of the matrix. When we removed these genes the error vanished and the program ran successfully.
Could you please post the full stacktrace and ideally provide us with a minimal working example to more easily find out what's going wrong? Can you create an artificial AnnData object that has the properties where the function fails? Can you create a subset of your data and then recreate an AnnData object that looks similar and leads to the issue?
Please make sure these conditions are met
What happened?
When we tried to compute QC metrics for our dataset we got this error (see title). Produced by the X.eliminate_zeros() call.
We also traced the error back to genes that have only zeros in them, which would remove these columns and thus change the shape of the matrix. When we removed these genes the error vanished and the program ran successfully.
Minimal code sample
sc.pp.calculate_qc_metrics(
raw_data, qc_vars=["mt", "ribo", "hb"], inplace=True, log1p=True
)
Error output
No response
Versions
The text was updated successfully, but these errors were encountered: