Skip to content

Commit

Permalink
Update cell_emb.py
Browse files Browse the repository at this point in the history
  • Loading branch information
jkobject authored Oct 18, 2024
1 parent 01e7885 commit e30dee5
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion scprint/tasks/cell_emb.py
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,7 @@ def __init__(
self.plot_corr_size = plot_corr_size
self.precision = precision
self.doplot = doplot
self.dtype = dtype
self.doclass = doclass
self.output_expression = output_expression
# subset_hvg=1000, use_layer='counts', is_symbol=True,force_preprocess=True, skip_validate=True)
Expand Down Expand Up @@ -153,7 +154,7 @@ def __call__(self, model: torch.nn.Module, adata: AnnData, cache=False):
model.doplot = self.doplot
with (
torch.no_grad(),
torch.autocast(device_type=device, dtype=torch.float16),
torch.autocast(device_type=device, dtype=self.dtype),
):
for batch in tqdm(dataloader):
gene_pos, expression, depth = (
Expand Down

0 comments on commit e30dee5

Please sign in to comment.