mirror of
https://github.com/ROCm/jax.git
synced 2025-04-19 05:16:06 +00:00
Merge pull request #19540 from mattjj:remove-hypothesis-test-dependence
PiperOrigin-RevId: 601908297
This commit is contained in:
commit
ccfe9c1ec2
@ -21,8 +21,6 @@ from typing import Any, Callable, TypeVar
|
||||
|
||||
from absl.testing import absltest
|
||||
from absl.testing import parameterized
|
||||
import hypothesis as hp
|
||||
import hypothesis.strategies as hps
|
||||
import jax
|
||||
from jax import random
|
||||
from jax import tree_util
|
||||
@ -33,6 +31,17 @@ import jax.numpy as jnp
|
||||
import numpy as np
|
||||
|
||||
|
||||
try:
|
||||
import hypothesis as hp
|
||||
import hypothesis.strategies as hps
|
||||
CAN_USE_HYPOTHESIS = True
|
||||
except (ModuleNotFoundError, ImportError):
|
||||
CAN_USE_HYPOTHESIS = False
|
||||
|
||||
if not CAN_USE_HYPOTHESIS:
|
||||
import sys; sys.exit(0)
|
||||
|
||||
|
||||
jax.config.parse_flags_with_absl()
|
||||
|
||||
hp.settings.register_profile(
|
||||
|
Loading…
x
Reference in New Issue
Block a user