How to use the gpytorch.test.utils.least_used_cuda_device function in gpytorch

To help you get started, we’ve selected a few gpytorch examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github cornellius-gp / gpytorch / test / distributions / test_multitask_multivariate_normal.py View on Github external
def test_multivariate_normal_batch_correlated_samples_cuda(self):
        if torch.cuda.is_available():
            with least_used_cuda_device():
                self.test_multivariate_normal_batch_correlated_samples(cuda=True)
github cornellius-gp / gpytorch / test / utils / test_quadrature.py View on Github external
def test_gauss_hermite_quadrature_1D_normal_nonbatch_cuda(self):
        if torch.cuda.is_available():
            with least_used_cuda_device():
                self.test_gauss_hermite_quadrature_1D_normal_nonbatch(cuda=True)
github cornellius-gp / gpytorch / test / utils / test_quadrature.py View on Github external
def test_gauss_hermite_quadrature_1D_mvn_batch_cuda(self):
        if torch.cuda.is_available():
            with least_used_cuda_device():
                self.test_gauss_hermite_quadrature_1D_normal_nonbatch(cuda=True)
github cornellius-gp / gpytorch / test / utils / test_quadrature.py View on Github external
def test_gauss_hermite_quadrature_1D_mvn_nonbatch_cuda(self):
        if torch.cuda.is_available():
            with least_used_cuda_device():
                self.test_gauss_hermite_quadrature_1D_normal_nonbatch(cuda=True)
github cornellius-gp / gpytorch / test / distributions / test_multitask_multivariate_normal.py View on Github external
def test_multitask_multivariate_normal_cuda(self):
        if torch.cuda.is_available():
            with least_used_cuda_device():
                self.test_multitask_multivariate_normal(cuda=True)
github cornellius-gp / gpytorch / test / priors / test_normal_prior.py View on Github external
def test_normal_prior_batch_log_prob_cuda(self):
        if torch.cuda.is_available():
            with least_used_cuda_device():
                return self.test_normal_prior_batch_log_prob(cuda=True)
github cornellius-gp / gpytorch / test / distributions / test_multitask_multivariate_normal.py View on Github external
def test_from_independent_mvns_cuda(self):
        if torch.cuda.is_available():
            with least_used_cuda_device():
                self.test_from_independent_mvns(cuda=True)
github cornellius-gp / gpytorch / test / priors / test_multivariate_normal_prior.py View on Github external
def test_multivariate_normal_prior_log_prob_cuda(self):
        if torch.cuda.is_available():
            with least_used_cuda_device():
                return self.test_multivariate_normal_prior_log_prob(cuda=True)
github cornellius-gp / gpytorch / test / distributions / test_multitask_multivariate_normal.py View on Github external
def test_multivariate_normal_correlated_samples_cuda(self):
        if torch.cuda.is_available():
            with least_used_cuda_device():
                self.test_multivariate_normal_correlated_samples(cuda=True)
github cornellius-gp / gpytorch / test / priors / test_lkj_prior.py View on Github external
def test_lkj_prior_log_prob_cuda(self):
        if torch.cuda.is_available():
            with least_used_cuda_device():
                self.test_lkj_prior_log_prob(cuda=True)