Farama-Foundation / Jumpy

On-the-fly conversions between Jax and NumPy tensors
Apache License 2.0
46 stars 9 forks source link

Adds testing for jumpy can run all functions without jax, only numpy #21

Closed pseudo-rnd-thoughts closed 1 year ago

pseudo-rnd-thoughts commented 1 year ago

This PR adds tests for all functions in jumpy, either through testing the _which_np and _which_dtype which a majority of functions call or a custom test for random, safe and custom functions

This PR modifies the _which_dtype to allow for optional dtypes and modifies the functions using is that if the dtype is None then the _which_np is used instead.

Adds np.linspace function