tinygrad/test
Liam 89d0ff6989
Consistent testing (#137)
* Consistent GPU classes

Convert the existing GPU classes into one standard format.

Remove duplicated functions in `test_mnist` and create a TestMNISTGPU
class. This reduces line count and ensures consistency.

Use `@unittest.skipUnless(GPU, "Requires GPU")` instead of `if GPU:` to
skip GPU testing. This will ensure that skipped tests are displayed
accordingly in the pytest output.

* Optim Testing now supports GPU

* Tensor testing now supports GPU

jacobian and gradcheck auto skipped until GPU float64 support added.

* GPU support for custom constructor methods

* Remove GPU flag from Model constructors

It was requested that the `gpu` kwarg be removed from the model
constructor. GPU conversion is now handled in the train function.

This also required the conversion of Optimizer parameters as they are
constructed prior to execution of the `train` function and are dependant
on the model GPU state.

* Fix typo: float32->float64

* Clean `get_parameters` utility

Just a quick refactor w/ the new support for optimizers.

* Remove GPU kwarg from TinyNet

Remove `gpu` kwarg from tiny net to match test_mnist `train` function.
2020-12-09 02:25:27 -08:00
..
test_gc.py win more lines for core library (#158) 2020-12-08 14:18:45 -08:00
test_mnist.py Consistent testing (#137) 2020-12-09 02:25:27 -08:00
test_net_speed.py gpu speedup, tests work on M1 2020-12-06 09:05:49 -08:00
test_nn.py gpu speedup, tests work on M1 2020-12-06 09:05:49 -08:00
test_ops.py Consistent testing (#137) 2020-12-09 02:25:27 -08:00
test_optim.py Consistent testing (#137) 2020-12-09 02:25:27 -08:00
test_tensor.py Consistent testing (#137) 2020-12-09 02:25:27 -08:00