-
Notifications
You must be signed in to change notification settings - Fork 342
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Training models with torch.Tensor input #2736
Comments
We cover the enhancement to use custom dataloader in the recent version of scVI-tools. |
Thanks! Is there already a link to an example usage of this new version? |
We are still talking about how this would work. However at the moment whenever I use rsc I have to transform back to cpu and than use scvi. Rapids-singlecell really wants |
Hi @j-bac, thanks for the suggestion. We will be releasing a tutorial with our next release (v1.2) that covers a basic usecase with a custom dataloader. I'll note that we currently don't support inference methods yet (e.g. |
Is your feature request related to a problem? Please describe.
It is not currently straightforward to pass external dataloaders to train a model. In particular, loading
torch.Tensor
data and directly feeding it to a model as input doesn't seem possible becausescvi.data._utils._check_nonnegative_integers
does not handletorch.Tensor
.It would be very useful to be able to feed a custom dataloader, dictionary or AnnData as direct input to model.train() without having to copy
torch.Tensor
back to numpy or pandas. Maybe this can be implemented usingmodel.train(data_module=data_module)
?Describe the solution you'd like
The text was updated successfully, but these errors were encountered: