Jax has [canonicalize_dtype](https://docs.jax.dev/en/latest/_autosummary/jax.dtypes.canonicalize_dtype.html) and PyTorch also has a notion of [default types](https://pytorch.org/docs/stable/generated/torch.set_default_dtype.html). Can we provide `canonicalize_dtype` for all libraries? Something like: ```python def canonicalize_dtype(xp: Namespace, dtype: DType | type[complex]) -> DType: if is_jax_namespace(xp): from jax.dtypes import canonicalize_dtype return canonicalize_dtype(dtype) # Suppresses warning. return xp.empty((), dtype=dtype).dtype ```