You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
(py39) C:\Users\leo\Gym-Trading-Env-main>python examples\example_environnement.py
Traceback (most recent call last):
File "C:\Users\leo\Gym-Trading-Env-main\examples\example_environnement.py", line 44, in
env.add_metric('Position Changes', lambda history : np.sum(np.diff(history['position']) != 0) )
File "C:\Users\leo\anaconda3\envs\py39\lib\site-packages\gymnasium\core.py", line 297, in getattr
logger.warn(
File "C:\Users\leo\anaconda3\envs\py39\lib\site-packages\gymnasium\logger.py", line 55, in warn
warnings.warn(
UserWarning: WARN: env.add_metric to get variables from other wrappers is deprecated and will be removed in v1.0, to get this variable you can do env.unwrapped.add_metric for environment variables or env.get_attr('add_metric') that will search the reminding wrappers.
need to fix: env.unwrapped.add_metric()
The text was updated successfully, but these errors were encountered:
(py39) C:\Users\leo\Gym-Trading-Env-main>python examples\example_environnement.py
Traceback (most recent call last):
File "C:\Users\leo\Gym-Trading-Env-main\examples\example_environnement.py", line 44, in
env.add_metric('Position Changes', lambda history : np.sum(np.diff(history['position']) != 0) )
File "C:\Users\leo\anaconda3\envs\py39\lib\site-packages\gymnasium\core.py", line 297, in getattr
logger.warn(
File "C:\Users\leo\anaconda3\envs\py39\lib\site-packages\gymnasium\logger.py", line 55, in warn
warnings.warn(
UserWarning: WARN: env.add_metric to get variables from other wrappers is deprecated and will be removed in v1.0, to get this variable you can do
env.unwrapped.add_metric
for environment variables orenv.get_attr('add_metric')
that will search the reminding wrappers.need to fix: env.unwrapped.add_metric()
The text was updated successfully, but these errors were encountered: