cornellius-gp / gpytorch

A highly efficient implementation of Gaussian Processes in PyTorch
MIT License
3.46k stars 545 forks source link

[Bug]Function RootDecompositionBackward error when batch_size > 10 with MultiTaskDeepGP #2531

Open ybwang75 opened 2 weeks ago

ybwang75 commented 2 weeks ago

In my model, I have constructed a MultiTaskDeepDP object named A. I performed rsample on the A for sampling some samples to concatenate with other model. Because of this, I initially set gpytorch.settings.num_likelihood_samples(1).

Additionally, since I need to index values when computing the MLL loss, I indexed the mean and covariance of A to obtain two submatrices. I then used these two submatrices to reconstruct a MultiTaskDeepDP object named B, which I used to compute the MLL loss. However, I am now encountering the following error:

image

When I set my batch size to 10 or less, no error occurs. However, if it exceeds 10, I encounter the error. Can anyone help me resolve this issue?