Skip to content

Commit

Permalink
more debugging logic (will remove these commits when done)
Browse files Browse the repository at this point in the history
  • Loading branch information
Mr4k committed Jul 14, 2023
1 parent ebeb5c7 commit ef75892
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions test/test_mps.py
Original file line number Diff line number Diff line change
Expand Up @@ -10608,9 +10608,6 @@ def get_samples():
if (op.name == "tensor_split" and isinstance(mps_args[1], torch.Tensor)):
mps_args[1] = cpu_args[1]

print("inputs:", cpu_args, cpu_kwargs)
print("outputs:", mps_args, mps_kwargs)

cpu_out = op(*cpu_args, **cpu_kwargs)
mps_out = op(*mps_args, **mps_kwargs)

Expand Down Expand Up @@ -10638,8 +10635,6 @@ def get_samples():
atol = None
rtol = None

print("cpu out:", cpu_out)
print("mps out:", mps_out)
self.assertEqual(cpu_out, mps_out, atol=atol, rtol=rtol)

#
Expand Down Expand Up @@ -10679,6 +10674,8 @@ def req_grad(t):
atol = 1e-3
rtol = 1e-3

print("cpu grad inputs:", cpu_grad_inputs)
print("mps grad inputs:", mps_grad_inputs)
self.assertEqual(cpu_grad_inputs, mps_grad_inputs, atol=atol, rtol=rtol)


Expand Down

0 comments on commit ef75892

Please sign in to comment.