You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am trying to run your repo; after fixing a urlib3 issue, downgrading to 1.26.18 rather than 2.0.5, I get the next error:
RuntimeError: Failed to import transformers.models.distilbert.modeling_tf_distilbert because of the following error (look up to see its traceback): No module named 'keras.engine'
Traceback: File "/Users/user/anaconda3/lib/python3.11/site-packages/streamlit/runtime/scriptrunner/script_runner.py", line 534, in _run_script exec(code, module.__dict__) File "/Users/user/Documents/Git/CAVE-demo/app.py", line 511, in <module> main() File "/Users/user/Documents/Git/CAVE-demo/app.py", line 508, in main correct_products(config) File "/Users/user/Documents/Git/CAVE-demo/app.py", line 350, in correct_products model, model_ckpt = choose_model(config) ^^^^^^^^^^^^^^^^^^^^ File "/Users/user/Documents/Git/CAVE-demo/app.py", line 134, in choose_model return load_model(model_ckpt), model_ckpt ^^^^^^^^^^^^^^^^^^^^^^ File "/Users/user/anaconda3/lib/python3.11/site-packages/streamlit/runtime/legacy_caching/caching.py", line 716, in wrapped_func return get_or_create_cached_value() ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/Users/user/anaconda3/lib/python3.11/site-packages/streamlit/runtime/legacy_caching/caching.py", line 697, in get_or_create_cached_value return_value = non_optional_func(*args, **kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/Users/user/Documents/Git/CAVE-demo/app.py", line 47, in load_model return AttributeExtractor(model_ckpt) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/Users/user/Documents/Git/CAVE-demo/attribute_extractor.py", line 14, in __init__ self.model = TFAutoModelForQuestionAnswering.from_pretrained(self.model_ckpt) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/Users/user/anaconda3/lib/python3.11/site-packages/transformers/models/auto/auto_factory.py", line 466, in from_pretrained model_class = _get_model_class(config, cls._model_mapping) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/Users/user/anaconda3/lib/python3.11/site-packages/transformers/models/auto/auto_factory.py", line 360, in _get_model_class supported_models = model_mapping[type(config)] ~~~~~~~~~~~~~^^^^^^^^^^^^^^ File "/Users/user/anaconda3/lib/python3.11/site-packages/transformers/models/auto/auto_factory.py", line 598, in __getitem__ return self._load_attr_from_module(model_type, model_name) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/Users/user/anaconda3/lib/python3.11/site-packages/transformers/models/auto/auto_factory.py", line 612, in _load_attr_from_module return getattribute_from_module(self._modules[module_name], attr) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/Users/user/anaconda3/lib/python3.11/site-packages/transformers/models/auto/auto_factory.py", line 557, in getattribute_from_module if hasattr(module, attr): ^^^^^^^^^^^^^^^^^^^^^ File "/Users/user/anaconda3/lib/python3.11/site-packages/transformers/utils/import_utils.py", line 1162, in __getattr__ module = self._get_module(self._class_to_module[name]) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/Users/user/anaconda3/lib/python3.11/site-packages/transformers/utils/import_utils.py", line 1174, in _get_module raise RuntimeError(
Any suggestions?
Thank you.
The text was updated successfully, but these errors were encountered:
Dear authors,
Congratulations to your publication.
I am trying to run your repo; after fixing a urlib3 issue, downgrading to 1.26.18 rather than 2.0.5, I get the next error:
RuntimeError: Failed to import transformers.models.distilbert.modeling_tf_distilbert because of the following error (look up to see its traceback): No module named 'keras.engine'
Traceback: File "/Users/user/anaconda3/lib/python3.11/site-packages/streamlit/runtime/scriptrunner/script_runner.py", line 534, in _run_script exec(code, module.__dict__) File "/Users/user/Documents/Git/CAVE-demo/app.py", line 511, in <module> main() File "/Users/user/Documents/Git/CAVE-demo/app.py", line 508, in main correct_products(config) File "/Users/user/Documents/Git/CAVE-demo/app.py", line 350, in correct_products model, model_ckpt = choose_model(config) ^^^^^^^^^^^^^^^^^^^^ File "/Users/user/Documents/Git/CAVE-demo/app.py", line 134, in choose_model return load_model(model_ckpt), model_ckpt ^^^^^^^^^^^^^^^^^^^^^^ File "/Users/user/anaconda3/lib/python3.11/site-packages/streamlit/runtime/legacy_caching/caching.py", line 716, in wrapped_func return get_or_create_cached_value() ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/Users/user/anaconda3/lib/python3.11/site-packages/streamlit/runtime/legacy_caching/caching.py", line 697, in get_or_create_cached_value return_value = non_optional_func(*args, **kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/Users/user/Documents/Git/CAVE-demo/app.py", line 47, in load_model return AttributeExtractor(model_ckpt) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/Users/user/Documents/Git/CAVE-demo/attribute_extractor.py", line 14, in __init__ self.model = TFAutoModelForQuestionAnswering.from_pretrained(self.model_ckpt) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/Users/user/anaconda3/lib/python3.11/site-packages/transformers/models/auto/auto_factory.py", line 466, in from_pretrained model_class = _get_model_class(config, cls._model_mapping) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/Users/user/anaconda3/lib/python3.11/site-packages/transformers/models/auto/auto_factory.py", line 360, in _get_model_class supported_models = model_mapping[type(config)] ~~~~~~~~~~~~~^^^^^^^^^^^^^^ File "/Users/user/anaconda3/lib/python3.11/site-packages/transformers/models/auto/auto_factory.py", line 598, in __getitem__ return self._load_attr_from_module(model_type, model_name) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/Users/user/anaconda3/lib/python3.11/site-packages/transformers/models/auto/auto_factory.py", line 612, in _load_attr_from_module return getattribute_from_module(self._modules[module_name], attr) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/Users/user/anaconda3/lib/python3.11/site-packages/transformers/models/auto/auto_factory.py", line 557, in getattribute_from_module if hasattr(module, attr): ^^^^^^^^^^^^^^^^^^^^^ File "/Users/user/anaconda3/lib/python3.11/site-packages/transformers/utils/import_utils.py", line 1162, in __getattr__ module = self._get_module(self._class_to_module[name]) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/Users/user/anaconda3/lib/python3.11/site-packages/transformers/utils/import_utils.py", line 1174, in _get_module raise RuntimeError(
Any suggestions?
Thank you.
The text was updated successfully, but these errors were encountered: