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

AttributeError: module 'keras.utils.generic_utils' has no attribute 'populate_dict_with_module_objects' #8

Open
s-inoue-univ opened this issue Aug 7, 2022 · 0 comments

Comments

@s-inoue-univ
Copy link

s-inoue-univ commented Aug 7, 2022

Overview

I cannot run the sample code because I get the following error.

(work) [ACCOUNT_NAME@es1 xai-bench]$ python main_driver.py --mode regression --seed 7 --experiment --experiment-json configs/experiment_config.jsonc --no-logs
IPython could not be loaded!
2022-08-07 16:01:34.898102: W tensorflow/stream_executor/platform/default/dso_loader.cc:64] Could not load dynamic library 'libcudart.so.11.0'; dlerror: libcudart.so.11.0: cannot open shared object file: No such file or directory; LD_LIBRARY_PATH: /apps/centos7/python/3.8.13_gcc11.2.0/lib:/apps/centos7/gcc/11.2.0/lib64
2022-08-07 16:01:34.898143: I tensorflow/stream_executor/cuda/cudart_stub.cc:29] Ignore above cudart dlerror if you do not have a GPU set up on your machine.
Traceback (most recent call last):
  File "main_driver.py", line 15, in <module>
    from src import datasets, model, explainer, metric, experiments, parse_utils
  File "/home/ACCOUNT_NAME/xai-bench/src/explainer.py", line 1, in <module>
    from custom_explainers.breakdown import BreakDown
  File "/home/ACCOUNT_NAME/xai-bench/custom_explainers/__init__.py", line 7, in <module>
    from .l2x import L2X
  File "/home/ACCOUNT_NAME/xai-bench/custom_explainers/l2x.py", line 16, in <module>
    from keras.callbacks import ModelCheckpoint
  File "/home/ACCOUNT_NAME/work/lib/python3.8/site-packages/keras/__init__.py", line 20, in <module>
    from . import initializers
  File "/home/ACCOUNT_NAME/work/lib/python3.8/site-packages/keras/initializers/__init__.py", line 124, in <module>
    populate_deserializable_objects()
  File "/home/ACCOUNT_NAME/work/lib/python3.8/site-packages/keras/initializers/__init__.py", line 82, in populate_deserializable_objects
    generic_utils.populate_dict_with_module_objects(
AttributeError: module 'keras.utils.generic_utils' has no attribute 'populate_dict_with_module_objects'

execution environment

  • OS
    • CentOS Linux 7 (Core)
  • system information
    • Linux es1.abci.local 3.10.0-862.el7.x86_64 #1 SMP Fri Apr 20 16:44:24 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux
  • Python version
    • 3.8.8
  • Python packages
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

1 participant