question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Fails with "not enough empty droplets" error even though --low-count-threshold 2

See original GitHub issue

CellBender fails on my data with “not enough empty droplets” error even though I set --low-count-threshold to 2. The error & log itself are a bit weird (look at the scale of nUMI filtered). I get this exact error (with different UMI numbers) on 2 very different datasets.

cellbender:remove-background: 2019-11-06 00:23:12
cellbender:remove-background: Running remove-background
cellbender:remove-background: Loading data from directory ./rawdata/filtered_feature_bc_matrix/folder
cellbender:remove-background: CellRanger v3 format
cellbender:remove-background: Trimming dataset for inference.
cellbender:remove-background: Prior on counts in empty droplets is 6001
cellbender:remove-background: Prior on counts for cells is 49252
cellbender:remove-background: Excluding barcodes with counts below 4800
Traceback (most recent call last):
  File "/path/to/software/miniconda3/envs/mypyro/bin/cellbender", line 11, in <module>
    load_entry_point('cellbender', 'console_scripts', 'cellbender')()
  File "~/CellBender/cellbender/base_cli.py", line 101, in main
    cli_dict[args.tool].run(args)
  File "~/CellBender/cellbender/remove_background/cli.py", line 92, in run
    main(args)
  File "~/CellBender/cellbender/remove_background/cli.py", line 185, in main
    run_remove_background(args)
  File "~/CellBender/cellbender/remove_background/cli.py", line 143, in run_remove_background
    args.low_count_threshold)
  File "~/CellBender/cellbender/remove_background/data/dataset.py", line 90, in __init__
    gene_blacklist=gene_blacklist)
  File "~/CellBender/cellbender/remove_background/data/dataset.py", line 252, in _trim_dataset_for_analysis
    f"There are no empty droplets with UMI counts over the lower " \
AssertionError: There are no empty droplets with UMI counts over the lower cutoff of 4800.  Some empty droplets are necessary for the analysis.Reduce the --low-count-threshold parameter.

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:10 (6 by maintainers)

github_iconTop GitHub Comments

2reactions
sjflemingcommented, May 3, 2021

@bobermayer Good to know! Yes, I have seen this kind of error happen before in the case where the “filtered” file is used by mistake. I’ve even done it myself… I should probably try to come up with some heuristic check so that a warning is issued if the file looks like it might be “filtered”.

In fact, I will do this, see #99

2reactions
bobermayercommented, Jan 5, 2021

I just ran into the same error until I realized that I had accidentally passed filtered_feature_bc_matrix.h5 instead of raw_feature_bc_matrix.h5 as input file. it looks like the same thing happened here.

Read more comments on GitHub >

github_iconTop Results From Across the Web

EmptyDrops: distinguishing cells from empty droplets in ...
An empty droplet does not contain a cell but will still contain “ambient” RNA [1], i.e., cell-free transcripts in the solution in which...
Read more >
remove-background - CellBender documentation
This warning indicates that no “surely empty” droplets were identified in the analysis. This means that the “empty droplet plateau” could not be...
Read more >
emptyDrops identified less non-empty cells with lower total ...
A secondary effect is that libraries with counts below lower are not tested by default, as we're already assuming that they're empty droplets...
Read more >
791699v2.full.pdf - bioRxiv
empty from non-empty droplets, and (2) to correctly recover the counts from encapsulated cells or nuclei while removing background counts.
Read more >
emptyDrops: Identify empty droplets in MarioniLab/DropletUtils
This is close to but not quite the same as identifying cells, as droplets containing cell fragments, stripped nuclei and damaged cells will ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found