Skip to content

Commit

Permalink
Try changing platform name
Browse files Browse the repository at this point in the history
  • Loading branch information
pomonam committed Oct 12, 2023
1 parent 5a0d3e8 commit ea8bac9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions algorithmic_efficiency/pytorch_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@ def pytorch_init(use_pytorch_ddp: bool, rank: int, profiler: Profiler) -> None:
# Only use CPU for Jax to avoid memory issues.
# Setting the corresponding environment variable here has no effect; it has to
# be done before jax and tensorflow (!) are imported for the first time.
os.environ['JAX_PLATFORMS'] = 'cpu'
jax.config.update('jax_platforms', 'cpu')
# os.environ['JAX_PLATFORMS'] = 'cpu'
jax.config.update('jax_platform_name', 'cpu')
# From the docs: "(...) causes cuDNN to benchmark multiple convolution
# algorithms and select the fastest."
torch.backends.cudnn.benchmark = True
Expand Down

0 comments on commit ea8bac9

Please sign in to comment.