Skip to content

Commit

Permalink
feat: add functionality for batch ambient removal
Browse files Browse the repository at this point in the history
  • Loading branch information
CaibinSh committed May 26, 2024
1 parent 5bc0d84 commit 353059f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion scar/main/_scar.py
Original file line number Diff line number Diff line change
Expand Up @@ -301,7 +301,7 @@ def __init__(

# add a mapper to locate the batch id
self.batch_id = torch.from_numpy(batch_id_per_cell).int().to(self.device)
self.n_batch = batch_id.unique().size()[0]
self.n_batch = np.unique(batch_id_per_cell).size

# get ambient profile from AnnData.uns
elif (ambient_profile is None) and ("ambient_profile_all" in raw_count.uns):
Expand Down

0 comments on commit 353059f

Please sign in to comment.