Merge pull request #14789 from patrick-kidger:patch-2

PiperOrigin-RevId: 514490253
This commit is contained in:
jax authors 2023-03-06 12:27:53 -08:00
commit 7d154103e3

View File

@ -162,6 +162,8 @@ def _dtype(x: Any) -> DType:
# types return JAX arrays when instantiated.
class _ScalarMeta(type):
dtype: np.dtype
def __hash__(self) -> int:
return hash(self.dtype.type)