你好,之前的错误是因为numpy的版本错误,纠正版本后,仍然有报错,如下:(一定要安装cuda库吗?我的机器是云上虚拟机,没有cuda设备)
2023-02-11 05:01:10.764147: E tensorflow/compiler/xla/stream_executor/cuda/cuda_driver.cc:267] failed call to cuInit: CUDA_ERROR_NO_DEVICE: no CUDA-capable device is detected
2023-02-11 05:01:10.764322: I tensorflow/compiler/xla/stream_executor/cuda/cuda_diagnostics.cc:156] kernel driver does not appear to be running on this host (qinh154): /proc/driver/nvidia/version does not exist
numpy() is only available when eager execution is enabled.
Traceback (most recent call last):
File "/mnt/disk01/hadb-opengauss/opengauss/bin/dbmind/components/xtuner/tuner/main.py", line 262, in main
return procedure_main(mode, db_info, config)
File "/mnt/disk01/hadb-opengauss/opengauss/bin/dbmind/components/xtuner/tuner/xtuner.py", line 130, in procedure_main
rl_model('train', env, config)
File "/mnt/disk01/hadb-opengauss/opengauss/bin/dbmind/components/xtuner/tuner/xtuner.py", line 174, in rl_model
rl = RLAgent(env, alg=config['rl_algorithm'])
File "/mnt/disk01/hadb-opengauss/opengauss/bin/dbmind/components/xtuner/tuner/algorithms/rl_agent.py", line 33, in __init__
self.agent = self._build_ddpg(nb_actions, nb_states)
File "/mnt/disk01/hadb-opengauss/opengauss/bin/dbmind/components/xtuner/tuner/algorithms/rl_agent.py", line 94, in _build_ddpg
ddpg.compile(Adam(), metrics=['mae'])
File "/mnt/disk01/hadb-opengauss/python3/lib/python3.8/site-packages/rl/agents/ddpg.py", line 79, in compile
critic_optimizer = clone_optimizer(optimizer)
File "/mnt/disk01/hadb-opengauss/python3/lib/python3.8/site-packages/rl/util.py", line 25, in clone_optimizer
params = {k: v for k, v in optimizer.get_config().items()}
File "/mnt/disk01/hadb-opengauss/python3/lib/python3.8/site-packages/keras/optimizers/optimizer_experimental/adam.py", line 207, in get_config
"learning_rate": self._serialize_hyperparameter(
File "/mnt/disk01/hadb-opengauss/python3/lib/python3.8/site-packages/keras/optimizers/optimizer_experimental/optimizer.py", line 718, in _serialize_hyperparameter
return hyperparameter.numpy()
新大陆软件 秦浩
mobile: 17625988619
e-mail:qinhao@newland.com.cn