AttributeError: 'SnakeEnv' object has no attribute 'seed'
运行环境:
Azure VM size: Standard NC24ads A100 v4
具体输出如下:
(SnakeAI) \snake-ai-master\main>python train_cnn.py
C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py:311: UserWarning: ←[33mWARN: env.seed to get variables from other wrappers is deprecated and will be removed in v1.0, to get this variable you can do `env.unwrapped.seed` for environment variables or `env.get_wrapper_attr('seed')` that will search the reminding wrappers.←[0m
logger.warn(
Process SpawnProcess-7:
Traceback (most recent call last):
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 315, in _bootstrap
self.run()
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 108, in run
self._target(*self._args, **self._kwargs)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\stable_baselines3\common\vec_env\subproc_vec_env.py", line 29, in _worker
env = _patch_env(env_fn_wrapper.var())
File "train_cnn.py", line 41, in _init
env.seed(seed)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
AttributeError: 'SnakeEnv' object has no attribute 'seed'
C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py:311: UserWarning: ←[33mWARN: env.seed to get variables from other wrappers is deprecated and will be removed in v1.0, to get this variable you can do `env.unwrapped.seed` for environment variables or `env.get_wrapper_attr('seed')` that will search the reminding wrappers.←[0m
logger.warn(
Process SpawnProcess-5:
Traceback (most recent call last):
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 315, in _bootstrap
self.run()
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 108, in run
self._target(*self._args, **self._kwargs)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\stable_baselines3\common\vec_env\subproc_vec_env.py", line 29, in _worker
env = _patch_env(env_fn_wrapper.var())
File "train_cnn.py", line 41, in _init
env.seed(seed)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
AttributeError: 'SnakeEnv' object has no attribute 'seed'
C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py:311: UserWarning: ←[33mWARN: env.seed to get variables from other wrappers is deprecated and will be removed in v1.0, to get this variable you can do `env.unwrapped.seed` for environment variables or `env.get_wrapper_attr('seed')` that will search the reminding wrappers.←[0m
logger.warn(
Process SpawnProcess-11:
C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py:311: UserWarning: ←[33mWARN: env.seed to get variables from other wrappers is deprecated and will be removed in v1.0, to get this variable you can do `env.unwrapped.seed` for environment variables or `env.get_wrapper_attr('seed')` that will search the reminding wrappers.←[0m
logger.warn(
Process SpawnProcess-14:
C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py:311: UserWarning: ←[33mWARN: env.seed to get variables from other wrappers is deprecated and will be removed in v1.0, to get this variable you can do `env.unwrapped.seed` for environment variables or `env.get_wrapper_attr('seed')` that will search the reminding wrappers.←[0m
logger.warn(
Process SpawnProcess-16:
Traceback (most recent call last):
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 315, in _bootstrap
self.run()
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 108, in run
self._target(*self._args, **self._kwargs)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\stable_baselines3\common\vec_env\subproc_vec_env.py", line 29, in _worker
env = _patch_env(env_fn_wrapper.var())
File "train_cnn.py", line 41, in _init
env.seed(seed)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
Traceback (most recent call last):
Traceback (most recent call last):
C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py:311: UserWarning: ←[33mWARN: env.seed to get variables from other wrappers is deprecated and will be removed in v1.0, to get this variable you can do `env.unwrapped.seed` for environment variables or `env.get_wrapper_attr('seed')` that will search the reminding wrappers.←[0m
logger.warn(
Process SpawnProcess-8:
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
AttributeError: 'SnakeEnv' object has no attribute 'seed'
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 315, in _bootstrap
self.run()
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 108, in run
self._target(*self._args, **self._kwargs)
Traceback (most recent call last):
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 315, in _bootstrap
self.run()
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 108, in run
self._target(*self._args, **self._kwargs)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\stable_baselines3\common\vec_env\subproc_vec_env.py", line 29, in _worker
env = _patch_env(env_fn_wrapper.var())
File "train_cnn.py", line 41, in _init
env.seed(seed)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
AttributeError: 'SnakeEnv' object has no attribute 'seed'
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\stable_baselines3\common\vec_env\subproc_vec_env.py", line 29, in _worker
env = _patch_env(env_fn_wrapper.var())
File "train_cnn.py", line 41, in _init
env.seed(seed)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
AttributeError: 'SnakeEnv' object has no attribute 'seed'
C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py:311: UserWarning: ←[33mWARN: env.seed to get variables from other wrappers is deprecated and will be removed in v1.0, to get this variable you can do `env.unwrapped.seed` for environment variables or `env.get_wrapper_attr('seed')` that will search the reminding wrappers.←[0m
logger.warn(
Process SpawnProcess-3:
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 315, in _bootstrap
self.run()
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 108, in run
self._target(*self._args, **self._kwargs)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\stable_baselines3\common\vec_env\subproc_vec_env.py", line 29, in _worker
env = _patch_env(env_fn_wrapper.var())
File "train_cnn.py", line 41, in _init
env.seed(seed)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
AttributeError: 'SnakeEnv' object has no attribute 'seed'
Traceback (most recent call last):
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 315, in _bootstrap
self.run()
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 108, in run
self._target(*self._args, **self._kwargs)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\stable_baselines3\common\vec_env\subproc_vec_env.py", line 29, in _worker
env = _patch_env(env_fn_wrapper.var())
File "train_cnn.py", line 41, in _init
env.seed(seed)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
AttributeError: 'SnakeEnv' object has no attribute 'seed'
C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py:311: UserWarning: ←[33mWARN: env.seed to get variables from other wrappers is deprecated and will be removed in v1.0, to get this variable you can do `env.unwrapped.seed` for environment variables or `env.get_wrapper_attr('seed')` that will search the reminding wrappers.←[0m
logger.warn(
Process SpawnProcess-1:
Traceback (most recent call last):
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 315, in _bootstrap
self.run()
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 108, in run
self._target(*self._args, **self._kwargs)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\stable_baselines3\common\vec_env\subproc_vec_env.py", line 29, in _worker
env = _patch_env(env_fn_wrapper.var())
File "train_cnn.py", line 41, in _init
env.seed(seed)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py:311: UserWarning: ←[33mWARN: env.seed to get variables from other wrappers is deprecated and will be removed in v1.0, to get this variable you can do `env.unwrapped.seed` for environment variables or `env.get_wrapper_attr('seed')` that will search the reminding wrappers.←[0m
logger.warn(
Process SpawnProcess-10:
AttributeError: 'SnakeEnv' object has no attribute 'seed'
C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py:311: UserWarning: ←[33mWARN: env.seed to get variables from other wrappers is deprecated and will be removed in v1.0, to get this variable you can do `env.unwrapped.seed` for environment variables or `env.get_wrapper_attr('seed')` that will search the reminding wrappers.←[0m
logger.warn(
Process SpawnProcess-24:
Traceback (most recent call last):
C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py:311: UserWarning: ←[33mWARN: env.seed to get variables from other wrappers is deprecated and will be removed in v1.0, to get this variable you can do `env.unwrapped.seed` for environment variables or `env.get_wrapper_attr('seed')` that will search the reminding wrappers.←[0m
logger.warn(
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 315, in _bootstrap
self.run()
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 108, in run
self._target(*self._args, **self._kwargs)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\stable_baselines3\common\vec_env\subproc_vec_env.py", line 29, in _worker
env = _patch_env(env_fn_wrapper.var())
Traceback (most recent call last):
C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py:311: UserWarning: ←[33mWARN: env.seed to get variables from other wrappers is deprecated and will be removed in v1.0, to get this variable you can do `env.unwrapped.seed` for environment variables or `env.get_wrapper_attr('seed')` that will search the reminding wrappers.←[0m
logger.warn(
C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py:311: UserWarning: ←[33mWARN: env.seed to get variables from other wrappers is deprecated and will be removed in v1.0, to get this variable you can do `env.unwrapped.seed` for environment variables or `env.get_wrapper_attr('seed')` that will search the reminding wrappers.←[0m
logger.warn(
Process SpawnProcess-15:
File "train_cnn.py", line 41, in _init
env.seed(seed)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 315, in _bootstrap
self.run()
Process SpawnProcess-4:
Process SpawnProcess-18:
Traceback (most recent call last):
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 315, in _bootstrap
self.run()
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 108, in run
self._target(*self._args, **self._kwargs)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\stable_baselines3\common\vec_env\subproc_vec_env.py", line 29, in _worker
env = _patch_env(env_fn_wrapper.var())
File "train_cnn.py", line 41, in _init
env.seed(seed)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 108, in run
self._target(*self._args, **self._kwargs)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
Traceback (most recent call last):
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 315, in _bootstrap
self.run()
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 108, in run
self._target(*self._args, **self._kwargs)
AttributeError: 'SnakeEnv' object has no attribute 'seed'
C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py:311: UserWarning: ←[33mWARN: env.seed to get variables from other wrappers is deprecated and will be removed in v1.0, to get this variable you can do `env.unwrapped.seed` for environment variables or `env.get_wrapper_attr('seed')` that will search the reminding wrappers.←[0m
logger.warn(
Process SpawnProcess-12:
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
AttributeError: 'SnakeEnv' object has no attribute 'seed'
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\stable_baselines3\common\vec_env\subproc_vec_env.py", line 29, in _worker
env = _patch_env(env_fn_wrapper.var())
File "train_cnn.py", line 41, in _init
env.seed(seed)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
AttributeError: 'SnakeEnv' object has no attribute 'seed'
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\stable_baselines3\common\vec_env\subproc_vec_env.py", line 29, in _worker
env = _patch_env(env_fn_wrapper.var())
File "train_cnn.py", line 41, in _init
env.seed(seed)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py:311: UserWarning: ←[33mWARN: env.seed to get variables from other wrappers is deprecated and will be removed in v1.0, to get this variable you can do `env.unwrapped.seed` for environment variables or `env.get_wrapper_attr('seed')` that will search the reminding wrappers.←[0m
logger.warn(
C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py:311: UserWarning: ←[33mWARN: env.seed to get variables from other wrappers is deprecated and will be removed in v1.0, to get this variable you can do `env.unwrapped.seed` for environment variables or `env.get_wrapper_attr('seed')` that will search the reminding wrappers.←[0m
logger.warn(
Process SpawnProcess-22:
Traceback (most recent call last):
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 315, in _bootstrap
self.run()
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 108, in run
self._target(*self._args, **self._kwargs)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\stable_baselines3\common\vec_env\subproc_vec_env.py", line 29, in _worker
env = _patch_env(env_fn_wrapper.var())
File "train_cnn.py", line 41, in _init
env.seed(seed)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
AttributeError: 'SnakeEnv' object has no attribute 'seed'
C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py:311: UserWarning: ←[33mWARN: env.seed to get variables from other wrappers is deprecated and will be removed in v1.0, to get this variable you can do `env.unwrapped.seed` for environment variables or `env.get_wrapper_attr('seed')` that will search the reminding wrappers.←[0m
logger.warn(
Process SpawnProcess-17:
Traceback (most recent call last):
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 315, in _bootstrap
self.run()
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 108, in run
self._target(*self._args, **self._kwargs)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\stable_baselines3\common\vec_env\subproc_vec_env.py", line 29, in _worker
env = _patch_env(env_fn_wrapper.var())
File "train_cnn.py", line 41, in _init
env.seed(seed)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
AttributeError: 'SnakeEnv' object has no attribute 'seed'
Traceback (most recent call last):
AttributeError: 'SnakeEnv' object has no attribute 'seed'
Traceback (most recent call last):
C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py:311: UserWarning: ←[33mWARN: env.seed to get variables from other wrappers is deprecated and will be removed in v1.0, to get this variable you can do `env.unwrapped.seed` for environment variables or `env.get_wrapper_attr('seed')` that will search the reminding wrappers.←[0m
logger.warn(
Process SpawnProcess-30:
Process SpawnProcess-21:
Traceback (most recent call last):
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 315, in _bootstrap
self.run()
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 108, in run
self._target(*self._args, **self._kwargs)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\stable_baselines3\common\vec_env\subproc_vec_env.py", line 29, in _worker
env = _patch_env(env_fn_wrapper.var())
File "train_cnn.py", line 41, in _init
env.seed(seed)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
AttributeError: 'SnakeEnv' object has no attribute 'seed'
C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py:311: UserWarning: ←[33mWARN: env.seed to get variables from other wrappers is deprecated and will be removed in v1.0, to get this variable you can do `env.unwrapped.seed` for environment variables or `env.get_wrapper_attr('seed')` that will search the reminding wrappers.←[0m
logger.warn(
Process SpawnProcess-20:
Traceback (most recent call last):
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 315, in _bootstrap
self.run()
C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py:311: UserWarning: ←[33mWARN: env.seed to get variables from other wrappers is deprecated and will be removed in v1.0, to get this variable you can do `env.unwrapped.seed` for environment variables or `env.get_wrapper_attr('seed')` that will search the reminding wrappers.←[0m
logger.warn(
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 315, in _bootstrap
self.run()
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 108, in run
self._target(*self._args, **self._kwargs)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\stable_baselines3\common\vec_env\subproc_vec_env.py", line 29, in _worker
env = _patch_env(env_fn_wrapper.var())
File "train_cnn.py", line 41, in _init
env.seed(seed)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 315, in _bootstrap
self.run()
C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py:311: UserWarning: ←[33mWARN: env.seed to get variables from other wrappers is deprecated and will be removed in v1.0, to get this variable you can do `env.unwrapped.seed` for environment variables or `env.get_wrapper_attr('seed')` that will search the reminding wrappers.←[0m
logger.warn(
C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py:311: UserWarning: ←[33mWARN: env.seed to get variables from other wrappers is deprecated and will be removed in v1.0, to get this variable you can do `env.unwrapped.seed` for environment variables or `env.get_wrapper_attr('seed')` that will search the reminding wrappers.←[0m
logger.warn(
Process SpawnProcess-26:
Traceback (most recent call last):
C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py:311: UserWarning: ←[33mWARN: env.seed to get variables from other wrappers is deprecated and will be removed in v1.0, to get this variable you can do `env.unwrapped.seed` for environment variables or `env.get_wrapper_attr('seed')` that will search the reminding wrappers.←[0m
logger.warn(
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 108, in run
self._target(*self._args, **self._kwargs)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\stable_baselines3\common\vec_env\subproc_vec_env.py", line 29, in _worker
env = _patch_env(env_fn_wrapper.var())
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 108, in run
self._target(*self._args, **self._kwargs)
Process SpawnProcess-2:
Process SpawnProcess-28:
Traceback (most recent call last):
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 315, in _bootstrap
self.run()
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 108, in run
self._target(*self._args, **self._kwargs)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\stable_baselines3\common\vec_env\subproc_vec_env.py", line 29, in _worker
env = _patch_env(env_fn_wrapper.var())
File "train_cnn.py", line 41, in _init
env.seed(seed)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
AttributeError: 'SnakeEnv' object has no attribute 'seed'
AttributeError: 'SnakeEnv' object has no attribute 'seed'
Traceback (most recent call last):
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 315, in _bootstrap
self.run()
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 108, in run
self._target(*self._args, **self._kwargs)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\stable_baselines3\common\vec_env\subproc_vec_env.py", line 29, in _worker
env = _patch_env(env_fn_wrapper.var())
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 315, in _bootstrap
self.run()
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 108, in run
self._target(*self._args, **self._kwargs)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\stable_baselines3\common\vec_env\subproc_vec_env.py", line 29, in _worker
env = _patch_env(env_fn_wrapper.var())
File "train_cnn.py", line 41, in _init
env.seed(seed)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
Process SpawnProcess-23:
File "train_cnn.py", line 41, in _init
env.seed(seed)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
AttributeError: 'SnakeEnv' object has no attribute 'seed'
Traceback (most recent call last):
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 315, in _bootstrap
self.run()
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 108, in run
self._target(*self._args, **self._kwargs)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\stable_baselines3\common\vec_env\subproc_vec_env.py", line 29, in _worker
env = _patch_env(env_fn_wrapper.var())
File "train_cnn.py", line 41, in _init
env.seed(seed)
Traceback (most recent call last):
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\stable_baselines3\common\vec_env\subproc_vec_env.py", line 29, in _worker
env = _patch_env(env_fn_wrapper.var())
File "train_cnn.py", line 41, in _init
env.seed(seed)
C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py:311: UserWarning: ←[33mWARN: env.seed to get variables from other wrappers is deprecated and will be removed in v1.0, to get this variable you can do `env.unwrapped.seed` for environment variables or `env.get_wrapper_attr('seed')` that will search the reminding wrappers.←[0m
logger.warn(
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 315, in _bootstrap
self.run()
C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py:311: UserWarning: ←[33mWARN: env.seed to get variables from other wrappers is deprecated and will be removed in v1.0, to get this variable you can do `env.unwrapped.seed` for environment variables or `env.get_wrapper_attr('seed')` that will search the reminding wrappers.←[0m
logger.warn(
Process SpawnProcess-13:
Process SpawnProcess-27:
AttributeError: 'SnakeEnv' object has no attribute 'seed'
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 108, in run
self._target(*self._args, **self._kwargs)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\stable_baselines3\common\vec_env\subproc_vec_env.py", line 29, in _worker
env = _patch_env(env_fn_wrapper.var())
File "train_cnn.py", line 41, in _init
env.seed(seed)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
AttributeError: 'SnakeEnv' object has no attribute 'seed'
Traceback (most recent call last):
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 315, in _bootstrap
self.run()
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 108, in run
self._target(*self._args, **self._kwargs)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\stable_baselines3\common\vec_env\subproc_vec_env.py", line 29, in _worker
env = _patch_env(env_fn_wrapper.var())
File "train_cnn.py", line 41, in _init
env.seed(seed)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
AttributeError: 'SnakeEnv' object has no attribute 'seed'
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
AttributeError: 'SnakeEnv' object has no attribute 'seed'
Traceback (most recent call last):
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 315, in _bootstrap
self.run()
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 108, in run
self._target(*self._args, **self._kwargs)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\stable_baselines3\common\vec_env\subproc_vec_env.py", line 29, in _worker
env = _patch_env(env_fn_wrapper.var())
File "train_cnn.py", line 41, in _init
env.seed(seed)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
AttributeError: 'SnakeEnv' object has no attribute 'seed'
C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py:311: UserWarning: ←[33mWARN: env.seed to get variables from other wrappers is deprecated and will be removed in v1.0, to get this variable you can do `env.unwrapped.seed` for environment variables or `env.get_wrapper_attr('seed')` that will search the reminding wrappers.←[0m
logger.warn(
Process SpawnProcess-9:
File "train_cnn.py", line 41, in _init
env.seed(seed)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
AttributeError: 'SnakeEnv' object has no attribute 'seed'
C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py:311: UserWarning: ←[33mWARN: env.seed to get variables from other wrappers is deprecated and will be removed in v1.0, to get this variable you can do `env.unwrapped.seed` for environment variables or `env.get_wrapper_attr('seed')` that will search the reminding wrappers.←[0m
logger.warn(
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
Traceback (most recent call last):
C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py:311: UserWarning: ←[33mWARN: env.seed to get variables from other wrappers is deprecated and will be removed in v1.0, to get this variable you can do `env.unwrapped.seed` for environment variables or `env.get_wrapper_attr('seed')` that will search the reminding wrappers.←[0m
logger.warn(
Process SpawnProcess-31:
Process SpawnProcess-19:
Traceback (most recent call last):
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 315, in _bootstrap
self.run()
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 315, in _bootstrap
self.run()
Traceback (most recent call last):
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\connection.py", line 312, in _recv_bytes
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 108, in run
self._target(*self._args, **self._kwargs)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\stable_baselines3\common\vec_env\subproc_vec_env.py", line 29, in _worker
env = _patch_env(env_fn_wrapper.var())
File "train_cnn.py", line 41, in _init
env.seed(seed)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
AttributeError: 'SnakeEnv' object has no attribute 'seed'
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
AttributeError: 'SnakeEnv' object has no attribute 'seed'
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 108, in run
self._target(*self._args, **self._kwargs)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\stable_baselines3\common\vec_env\subproc_vec_env.py", line 29, in _worker
env = _patch_env(env_fn_wrapper.var())
File "train_cnn.py", line 41, in _init
env.seed(seed)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
AttributeError: 'SnakeEnv' object has no attribute 'seed'
nread, err = ov.GetOverlappedResult(True)
BrokenPipeError: [WinError 109] The pipe has been ended
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "train_cnn.py", line 119, in <module>
main()
File "train_cnn.py", line 53, in main
env = SubprocVecEnv([make_env(seed=s) for s in seed_set])
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\stable_baselines3\common\vec_env\subproc_vec_env.py", line 119, in __init__
C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py:311: UserWarning: ←[33mWARN: env.seed to get variables from other wrappers is deprecated and will be removed in v1.0, to get this variable you can do `env.unwrapped.seed` for environment variables or `env.get_wrapper_attr('seed')` that will search the reminding wrappers.←[0m
logger.warn(
C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py:311: UserWarning: ←[33mWARN: env.seed to get variables from other wrappers is deprecated and will be removed in v1.0, to get this variable you can do `env.unwrapped.seed` for environment variables or `env.get_wrapper_attr('seed')` that will search the reminding wrappers.←[0m
logger.warn(
Process SpawnProcess-6:
Traceback (most recent call last):
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 315, in _bootstrap
self.run()
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 108, in run
self._target(*self._args, **self._kwargs)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\stable_baselines3\common\vec_env\subproc_vec_env.py", line 29, in _worker
env = _patch_env(env_fn_wrapper.var())
File "train_cnn.py", line 41, in _init
env.seed(seed)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
AttributeError: 'SnakeEnv' object has no attribute 'seed'
C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py:311: UserWarning: ←[33mWARN: env.seed to get variables from other wrappers is deprecated and will be removed in v1.0, to get this variable you can do `env.unwrapped.seed` for environment variables or `env.get_wrapper_attr('seed')` that will search the reminding wrappers.←[0m
logger.warn(
Process SpawnProcess-29:
Process SpawnProcess-25:
Traceback (most recent call last):
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 315, in _bootstrap
self.run()
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 108, in run
self._target(*self._args, **self._kwargs)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\stable_baselines3\common\vec_env\subproc_vec_env.py", line 29, in _worker
env = _patch_env(env_fn_wrapper.var())
File "train_cnn.py", line 41, in _init
env.seed(seed)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
AttributeError: 'SnakeEnv' object has no attribute 'seed'
Traceback (most recent call last):
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 315, in _bootstrap
self.run()
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 108, in run
self._target(*self._args, **self._kwargs)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\stable_baselines3\common\vec_env\subproc_vec_env.py", line 29, in _worker
env = _patch_env(env_fn_wrapper.var())
File "train_cnn.py", line 41, in _init
env.seed(seed)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
AttributeError: 'SnakeEnv' object has no attribute 'seed'
Traceback (most recent call last):
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 315, in _bootstrap
self.run()
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\process.py", line 108, in run
self._target(*self._args, **self._kwargs)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\stable_baselines3\common\vec_env\subproc_vec_env.py", line 29, in _worker
env = _patch_env(env_fn_wrapper.var())
File "train_cnn.py", line 41, in _init
env.seed(seed)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\site-packages\gymnasium\core.py", line 315, in __getattr__
return getattr(self.env, name)
AttributeError: 'SnakeEnv' object has no attribute 'seed'
observation_space, action_space = self.remotes[0].recv()
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\connection.py", line 250, in recv
buf = self._recv_bytes()
File "C:\ProgramData\anaconda3\envs\SnakeAI\lib\multiprocessing\connection.py", line 321, in _recv_bytes
raise EOFError
EOFError
如题,运行test的时候没问题,运行train的时候会有报错,其中绝大多数error都是
运行环境: Azure VM size: Standard NC24ads A100 v4![image](https://github.com/linyiLYi/snake-ai/assets/106713170/a052a778-63df-4b4e-8a6d-8e5b67d4f044)
具体输出如下: