Error when training SCVI on reference data

When attempting to train a SCVI model for reference mapping, I get the following error

Expected parameter loc (Tensor of shape (128, 10)) of distribution Normal(loc: torch.Size([128, 10]), scale: torch.Size([128, 10])) to satisfy the constraint Real(), but found invalid values:

Here is the line of code scvi_model = scvi.model.SCVI(adata_train, **scvi_params)

Can you tell us more about your data and show us the code for setting up your anndata?

As shown in the screenshot, the training data has negative values because it is batch corrected data. So i suspect this error is a result of that. Is there a way to make this work? some normalization perhaps?

what is inside adata.layers['counts']? SCVI does indeed require count valued data