Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Problems with Tensorflow 2.4 #63

Open
synapp009 opened this issue Mar 10, 2021 · 1 comment
Open

Problems with Tensorflow 2.4 #63

synapp009 opened this issue Mar 10, 2021 · 1 comment

Comments

@synapp009
Copy link

synapp009 commented Mar 10, 2021

Hi,
because there are problems with new CUDA 11.2 to run Tensorflow 2.3 I had to update to 2.4.

I want to run dqn_train.
Now I got error because of problems with tf.compat.v1.disable_eager_execution( ) in agent_keras_rl_dqn.py:
AttributeError: 'TensorBoard' object has no attribute '_should_trace'

I changed to tf.compat.v1.enable_eager_execution(), now I get error:
AttributeError: 'DQNAgent' object has no attribute 'distribute_strategy'
If I try to add "distribute_strategy" to DQNAgent(main=.....), it doesn't change anything.
What to do?

Here complete log:

2021-03-10 14:42:29.846718: W tensorflow/stream_executor/platform/default/dso_loader.cc:60] Could not load dynamic library 'cupti64_110.dll'; dlerror: cupti64_110.dll not found
2021-03-10 14:42:29.849472: W tensorflow/stream_executor/platform/default/dso_loader.cc:60] Could not load dynamic library 'cupti.dll'; dlerror: cupti.dll not found
2021-03-10 14:42:29.849573: E tensorflow/core/profiler/internal/gpu/cupti_tracer.cc:1415] function cupti_interface_->Subscribe( &subscriber_, (CUpti_CallbackFunc)ApiCallback, this)failed with error CUPTI could not be loaded or symbol could not be found.
2021-03-10 14:42:29.849915: I tensorflow/core/profiler/lib/profiler_session.cc:172] Profiler session tear down.
2021-03-10 14:42:29.850186: E tensorflow/core/profiler/internal/gpu/cupti_tracer.cc:1496] function cupti_interface_->Finalize()failed with error CUPTI could not be loaded or symbol could not be found.
Traceback (most recent call last):
File "main.py", line 255, in
command_line_parser()
File "main.py", line 78, in command_line_parser
runner.dqn_train_keras_rl(model_name)
File "main.py", line 204, in dqn_train_keras_rl
dqn.train(env_name=model_name)
File "C:\Users\neuron_poker\agents\agent_keras_rl_dqn.py", line 102, in train
start_step_policy=self.start_step_policy, callbacks=[tensorboard])
File "C:\Users\Shadow.conda\envs\neuron_poker\lib\site-packages\rl\core.py", line 103, in fit
callbacks.set_model(self)
File "C:\Users\Shadow.conda\envs\neuron_poker\lib\site-packages\tensorflow\python\keras\callbacks.py", line 286, in set_model
callback.set_model(model)
File "C:\Users\Shadow.conda\envs\neuron_poker\lib\site-packages\tensorflow\python\keras\callbacks.py", line 2110, in set_model
self._log_write_dir = self._get_log_write_dir()
File "C:\Users\Shadow.conda\envs\neuron_poker\lib\site-packages\tensorflow\python\keras\callbacks.py", line 2143, in _get_log_write_dir
self.model.distribute_strategy)
AttributeError: 'DQNAgent' object has no attribute 'distribute_strategy'

@TripleExclam
Copy link

I had to revert to Tensorflow 2.3 to fix this error. See here: tensorflow/tensorflow#44563

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants