f7b10102a3a0b08272634347ff3a65efd3df18ce,test/functions/test_inv_matmul.py,TestInvMatmulNonBatch,test_inv_matmul_multiple_vecs,#TestInvMatmulNonBatch#,49

Before Change


            self.assertLess(torch.max((res - actual).abs() / actual.abs()).item(), 1e-3)

            // Backward
            grad_output = torch.randn(8, 4)
            res.backward(gradient=grad_output)
            actual.backward(gradient=grad_output)
            self.assertLess(torch.max((self.mat_copy.grad - self.mat.grad).abs()).item(), 1e-3)
            self.assertLess(torch.max((self.vecs_copy.grad - self.vecs.grad).abs()).item(), 1e-3)

After Change



    def test_inv_matmul_multiple_vecs(self):
        mat = self._create_mat().detach().requires_grad_(True)
        mat_copy = mat.detach().clone().requires_grad_(True)
        mat_copy.register_hook(_ensure_symmetric_grad)
        vecs = torch.randn(*mat.shape[:-2], mat.size(-1), 4).detach().requires_grad_(True)
        vecs_copy = vecs.detach().clone().requires_grad_(True)
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 4

Instances


Project Name: cornellius-gp/gpytorch
Commit Name: f7b10102a3a0b08272634347ff3a65efd3df18ce
Time: 2019-04-04
Author: gpleiss@gmail.com
File Name: test/functions/test_inv_matmul.py
Class Name: TestInvMatmulNonBatch
Method Name: test_inv_matmul_multiple_vecs


Project Name: cornellius-gp/gpytorch
Commit Name: 91b0d220c8e816766fd4565e1d2f5115d3afbefe
Time: 2018-10-12
Author: gpleiss@gmail.com
File Name: test/functions/test_inv_quad_log_det.py
Class Name: TestInvQuadLogDetBatch
Method Name: setUp


Project Name: cornellius-gp/gpytorch
Commit Name: 17e18750dd0b981460903ae631580d1d200509b5
Time: 2018-09-21
Author: balandat@fb.com
File Name: test/lazy/test_kronecker_product_lazy_tensor.py
Class Name: TestKroneckerProductLazyTensor
Method Name: test_matmul_batch_mat