AttributeError: module 'numpy.distutils.__config__' has no attribute 'blas_opt_info'

128 views
Skip to first unread message

Pallavi Sharma

unread,
Jan 31, 2022, 3:17:30 PM1/31/22
to theano-users
Hi Theano Users,

I am new with Theano and while importing this package I am running in to the below error. Please suggest.

===================================================

Traceback (most recent call last):
  File "/Users/pallavisharma/PycharmProjects/ExtractiveSummarization/venv/lib/python3.8/site-packages/theano/configparser.py", line 168, in fetch_val_for_key
    return theano_cfg.get(section, option)
  File "/Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/configparser.py", line 781, in get
    d = self._unify_values(section, vars)
  File "/Library/Frameworks/Python.framework/Versions/3.8/lib/python3.8/configparser.py", line 1149, in _unify_values
    raise NoSectionError(section) from None
configparser.NoSectionError: No section: 'blas'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
  File "/Users/pallavisharma/PycharmProjects/ExtractiveSummarization/venv/lib/python3.8/site-packages/theano/configparser.py", line 327, in __get__
    val_str = fetch_val_for_key(self.fullname,
  File "/Users/pallavisharma/PycharmProjects/ExtractiveSummarization/venv/lib/python3.8/site-packages/theano/configparser.py", line 172, in fetch_val_for_key
    raise KeyError(key)
KeyError: 'blas.ldflags'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
  File "<frozen importlib._bootstrap>", line 991, in _find_and_load
  File "<frozen importlib._bootstrap>", line 975, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 671, in _load_unlocked
  File "<frozen importlib._bootstrap_external>", line 783, in exec_module
  File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed
  File "/Users/pallavisharma/PycharmProjects/ExtractiveSummarization/rbm.py", line 19, in <module>
    import theano
  File "/Users/pallavisharma/PycharmProjects/ExtractiveSummarization/venv/lib/python3.8/site-packages/theano/__init__.py", line 124, in <module>
    from theano.scan_module import (scan, map, reduce, foldl, foldr, clone,
  File "/Users/pallavisharma/PycharmProjects/ExtractiveSummarization/venv/lib/python3.8/site-packages/theano/scan_module/__init__.py", line 41, in <module>
    from theano.scan_module import scan_opt
  File "/Users/pallavisharma/PycharmProjects/ExtractiveSummarization/venv/lib/python3.8/site-packages/theano/scan_module/scan_opt.py", line 60, in <module>
    from theano import tensor, scalar
  File "/Users/pallavisharma/PycharmProjects/ExtractiveSummarization/venv/lib/python3.8/site-packages/theano/tensor/__init__.py", line 17, in <module>
    from theano.tensor import blas
  File "/Users/pallavisharma/PycharmProjects/ExtractiveSummarization/venv/lib/python3.8/site-packages/theano/tensor/blas.py", line 155, in <module>
    from theano.tensor.blas_headers import blas_header_text
  File "/Users/pallavisharma/PycharmProjects/ExtractiveSummarization/venv/lib/python3.8/site-packages/theano/tensor/blas_headers.py", line 987, in <module>
    if not config.blas.ldflags:
  File "/Users/pallavisharma/PycharmProjects/ExtractiveSummarization/venv/lib/python3.8/site-packages/theano/configparser.py", line 332, in __get__
    val_str = self.default()
  File "/Users/pallavisharma/PycharmProjects/ExtractiveSummarization/venv/lib/python3.8/site-packages/theano/configdefaults.py", line 1284, in default_blas_ldflags
    blas_info = np.distutils.__config__.blas_opt_info
AttributeError: module 'numpy.distutils.__config__' has no attribute 'blas_opt_info'
python-BaseException
Reply all
Reply to author
Forward
0 new messages