remove cpu and torch backends (#3399)

* remove cpu and torch backends

* don't copy to cpu

* use clang instead of cpu

* multitensor gathers on the first device

* clang is cpu + use default

* fixup

* bugfix
This commit is contained in:
George Hotz
2024-02-15 16:55:39 +01:00
committed by GitHub
parent 75f7e21a80
commit b1c0d8c99d
12 changed files with 23 additions and 151 deletions

View File

@@ -23,10 +23,10 @@ def multidevice_test(fxn):
class TestExample(unittest.TestCase):
@multidevice_test
def test_convert_to_cpu(self, device):
def test_convert_to_clang(self, device):
a = Tensor([[1,2],[3,4]], device=device)
assert a.numpy().shape == (2,2)
b = a.cpu()
b = a.clang()
assert b.numpy().shape == (2,2)
@multidevice_test