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

nltk_data #19

Open
w123456789zy opened this issue Jul 30, 2024 · 0 comments
Open

nltk_data #19

w123456789zy opened this issue Jul 30, 2024 · 0 comments

Comments

@w123456789zy
Copy link

当我使用docker部署时,一直报如下错误:
2024-07-30 17:38:02 streamer-sales-tts-server | LookupError:
2024-07-30 17:38:02 streamer-sales-tts-server | **********************************************************************
2024-07-30 17:38:02 streamer-sales-tts-server | Resource cmudict not found.
2024-07-30 17:38:02 streamer-sales-tts-server | Please use the NLTK Downloader to obtain the resource:
2024-07-30 17:38:02 streamer-sales-tts-server |
2024-07-30 17:38:02 streamer-sales-tts-server | >>> import nltk
2024-07-30 17:38:02 streamer-sales-tts-server | >>> nltk.download('cmudict')
2024-07-30 17:38:02 streamer-sales-tts-server |
2024-07-30 17:38:02 streamer-sales-tts-server | For more information see: https://www.nltk.org/data.html
2024-07-30 17:38:02 streamer-sales-tts-server |
2024-07-30 17:38:02 streamer-sales-tts-server | Attempted to load corpora/cmudict
2024-07-30 17:38:02 streamer-sales-tts-server |
2024-07-30 17:38:02 streamer-sales-tts-server | Searched in:
2024-07-30 17:38:02 streamer-sales-tts-server | - '/root/nltk_data'
2024-07-30 17:38:02 streamer-sales-tts-server | - '/opt/conda/nltk_data'
2024-07-30 17:38:02 streamer-sales-tts-server | - '/opt/conda/share/nltk_data'
2024-07-30 17:38:02 streamer-sales-tts-server | - '/opt/conda/lib/nltk_data'
2024-07-30 17:38:02 streamer-sales-tts-server | - '/usr/share/nltk_data'
2024-07-30 17:38:02 streamer-sales-tts-server | - '/usr/local/share/nltk_data'
2024-07-30 17:38:02 streamer-sales-tts-server | - '/usr/lib/nltk_data'
2024-07-30 17:38:02 streamer-sales-tts-server | - '/usr/local/lib/nltk_data'
2024-07-30 17:38:02 streamer-sales-tts-server | **********************************************************************

2024-07-30 17:37:40 streamer-sales-llm-server | Traceback (most recent call last):
2024-07-30 17:37:40 streamer-sales-llm-server | File "/opt/conda/lib/python3.10/site-packages/modelscope/utils/ast_utils.py", line 466, in _get_single_file_scan_result
2024-07-30 17:37:40 streamer-sales-llm-server | output = self.astScaner.generate_ast(file)
2024-07-30 17:37:40 streamer-sales-llm-server | File "/opt/conda/lib/python3.10/site-packages/modelscope/utils/ast_utils.py", line 365, in generate_ast
2024-07-30 17:37:40 streamer-sales-llm-server | output = self.scan_import(node, show_offsets=False)
2024-07-30 17:37:40 streamer-sales-llm-server | File "/opt/conda/lib/python3.10/site-packages/modelscope/utils/ast_utils.py", line 164, in scan_import
2024-07-30 17:37:40 streamer-sales-llm-server | local_out = _scan_import(el, type(el).name)
2024-07-30 17:37:40 streamer-sales-llm-server | File "/opt/conda/lib/python3.10/site-packages/modelscope/utils/ast_utils.py", line 133, in _scan_import
2024-07-30 17:37:40 streamer-sales-llm-server | return self.scan_import(
2024-07-30 17:37:40 streamer-sales-llm-server | File "/opt/conda/lib/python3.10/site-packages/modelscope/utils/ast_utils.py", line 151, in scan_import
2024-07-30 17:37:40 streamer-sales-llm-server | attr = getattr(node, field)
2024-07-30 17:37:40 streamer-sales-llm-server | AttributeError: 'ClassDef' object has no attribute 'type_params'
2024-07-30 17:37:40 streamer-sales-llm-server |
2024-07-30 17:37:40 streamer-sales-llm-server | During handling of the above exception, another exception occurred:
2024-07-30 17:37:40 streamer-sales-llm-server |
2024-07-30 17:37:40 streamer-sales-llm-server | Traceback (most recent call last):
2024-07-30 17:37:40 streamer-sales-llm-server | File "/opt/conda/bin/lmdeploy", line 8, in
2024-07-30 17:37:40 streamer-sales-llm-server | sys.exit(run())
2024-07-30 17:37:40 streamer-sales-llm-server | File "/opt/conda/lib/python3.10/site-packages/lmdeploy/cli/entrypoint.py", line 30, in run
2024-07-30 17:37:40 streamer-sales-llm-server | args.model_path = get_model(args.model_path)
2024-07-30 17:37:40 streamer-sales-llm-server | File "/opt/conda/lib/python3.10/site-packages/lmdeploy/utils.py", line 202, in get_model
2024-07-30 17:37:40 streamer-sales-llm-server | from modelscope import snapshot_download
2024-07-30 17:37:40 streamer-sales-llm-server | File "/opt/conda/lib/python3.10/site-packages/modelscope/init.py", line 4, in
2024-07-30 17:37:40 streamer-sales-llm-server | from modelscope.utils.import_utils import LazyImportModule
2024-07-30 17:37:40 streamer-sales-llm-server | File "/opt/conda/lib/python3.10/site-packages/modelscope/utils/init.py", line 1, in
2024-07-30 17:37:40 streamer-sales-llm-server | from .hub import create_model_if_not_exist, read_config
2024-07-30 17:37:40 streamer-sales-llm-server | File "/opt/conda/lib/python3.10/site-packages/modelscope/utils/hub.py", line 12, in
2024-07-30 17:37:40 streamer-sales-llm-server | from modelscope.utils.config import Config
2024-07-30 17:37:40 streamer-sales-llm-server | File "/opt/conda/lib/python3.10/site-packages/modelscope/utils/config.py", line 22, in
2024-07-30 17:37:40 streamer-sales-llm-server | from modelscope.utils.import_utils import import_modules_from_file
2024-07-30 17:37:40 streamer-sales-llm-server | File "/opt/conda/lib/python3.10/site-packages/modelscope/utils/import_utils.py", line 380, in
2024-07-30 17:37:40 streamer-sales-llm-server | class LazyImportModule(ModuleType):
2024-07-30 17:37:40 streamer-sales-llm-server | File "/opt/conda/lib/python3.10/site-packages/modelscope/utils/import_utils.py", line 383, in LazyImportModule
2024-07-30 17:37:40 streamer-sales-llm-server | AST_INDEX = load_index()
2024-07-30 17:37:40 streamer-sales-llm-server | File "/opt/conda/lib/python3.10/site-packages/modelscope/utils/ast_utils.py", line 722, in load_index
2024-07-30 17:37:40 streamer-sales-llm-server | _update_index(index, files_mtime)
2024-07-30 17:37:40 streamer-sales-llm-server | File "/opt/conda/lib/python3.10/site-packages/modelscope/utils/ast_utils.py", line 638, in _update_index
2024-07-30 17:37:40 streamer-sales-llm-server | updated_index = file_scanner.get_files_scan_results(updated_files)
2024-07-30 17:37:40 streamer-sales-llm-server | File "/opt/conda/lib/python3.10/site-packages/modelscope/utils/ast_utils.py", line 532, in get_files_scan_results
2024-07-30 17:37:40 streamer-sales-llm-server | decorator_list, import_list = self._get_single_file_scan_result(
2024-07-30 17:37:40 streamer-sales-llm-server | File "/opt/conda/lib/python3.10/site-packages/modelscope/utils/ast_utils.py", line 469, in _get_single_file_scan_result
2024-07-30 17:37:40 streamer-sales-llm-server | raise Exception(
2024-07-30 17:37:40 streamer-sales-llm-server | Exception: During ast indexing the file /opt/conda/lib/python3.10/site-packages/modelscope/models/multi_modal/ofa_for_text_to_image_synthesis_model.py, a related error excepted in the file /opt/conda/lib/python3.10/site-packages/modelscope/utils/ast_utils.py at line: 151: "attr = getattr(node, field)" with error msg: "AttributeError: 'ClassDef' object has no attribute 'type_params'", please double check the origin file /opt/conda/lib/python3.10/site-packages/modelscope/models/multi_modal/ofa_for_text_to_image_synthesis_model.py to see whether the file is correctly edited.

请问怎么解决?

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