Skip to content

Commit

Permalink
Fix pre-commit
Browse files Browse the repository at this point in the history
  • Loading branch information
benjamc committed Dec 11, 2023
1 parent 7df9d72 commit 134f161
Show file tree
Hide file tree
Showing 5 changed files with 2 additions and 13 deletions.
4 changes: 1 addition & 3 deletions carl/envs/gymnax/carl_gymnax_env.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,12 @@

import importlib

import gymnasium
import gymnax.environments
from gymnasium.core import Env

from carl.context.selection import AbstractSelector
from carl.envs.carl_env import CARLEnv
from carl.envs.gymnax.utils import make_gymnax_env
from carl.utils.types import Context, Contexts
from carl.utils.types import Contexts


class CARLGymnaxEnv(CARLEnv):
Expand Down
1 change: 0 additions & 1 deletion carl/envs/gymnax/classic_control/carl_gymnax_acrobot.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
from __future__ import annotations

import gymnax
import jax.numpy as jnp
import numpy as np

Expand Down
3 changes: 0 additions & 3 deletions carl/envs/gymnax/classic_control/carl_gymnax_cartpole.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,6 @@

import importlib

import gymnax
import jax.numpy as np

from carl.context.context_space import ContextFeature, UniformFloatContextFeature
from carl.envs.gymnax.carl_gymnax_env import CARLGymnaxEnv

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
from __future__ import annotations

import gymnax
import jax.numpy as np

from carl.context.context_space import ContextFeature, UniformFloatContextFeature
Expand Down
6 changes: 1 addition & 5 deletions carl/envs/gymnax/utils.py
Original file line number Diff line number Diff line change
@@ -1,17 +1,13 @@
from __future__ import annotations

from typing import Any, Optional, Sequence
from typing import Any

import gymnasium
import gymnasium.spaces
import gymnax
from gymnasium.wrappers import EnvCompatibility
from gymnasium.wrappers.compatibility import LegacyEnv
from gymnax.environments.environment import Environment, EnvParams
from gymnax.environments.spaces import Space, gymnax_space_to_gym_space
from gymnax.wrappers.gym import GymnaxToGymWrapper
from numpy._typing import DTypeLike
from numpy.random._generator import Generator as Generator


# Although this converts to gym, the step API already is for gymnasium
Expand Down

0 comments on commit 134f161

Please sign in to comment.