Script file 'D:\Anaconda\Scripts\pip-script.py' is not present. Traceback (most recent call last): File "D:\yolov7-lpr\yolov7_plate-master\utils\general.py", line 117, in check_requirements pkg.require(r) File "D:\Anaconda\lib\site-packages\pkg_resources\__init__.py", line 886, in require needed = self.resolve(parse_requirements(requirements)) File "D:\Anaconda\lib\site-packages\pkg_resources\__init__.py", line 772, in resolve raise DistributionNotFound(req, requirers) pkg_resources.DistributionNotFound: The 'onnx>=1.8.1' distribution was not found and is required by the application During handling of the above exception, another exception occurred: Traceback (most recent call last): File "D:/yolov7-lpr/yolov7_plate-master/detect.py", line 196, in <module> check_requirements(exclude=('tensorboard', 'pycocotools', 'thop')) File "D:\yolov7-lpr\yolov7_plate-master\utils\general.py", line 121, in check_requirements print(subprocess.check_output(f"pip install '{r}'", shell=True).decode()) File "D:\Anaconda\lib\subprocess.py", line 415, in check_output return run(*popenargs, stdout=PIPE, timeout=timeout, check=True, File "D:\Anaconda\lib\subprocess.py", line 516, in run raise CalledProcessError(retcode, process.args, subprocess.CalledProcessError: Command 'pip install 'onnx>=1.8.1'' returned non-zero exit status 105.
时间: 2023-06-27 18:04:42 浏览: 224
看起来你在运行代码时缺少了 `onnx` 库。根据错误信息显示,你需要安装 `onnx>=1.8.1` 才能成功运行代码。你可以尝试在命令行中运行以下命令来安装 `onnx` 库:
```
pip install onnx>=1.8.1
```
如果你使用的是 Anaconda 环境,可以尝试在 Anaconda Prompt 中运行以上命令来安装 `onnx` 库。
相关问题
cmd 打开jupyter notebook 报错:Traceback (most recent call last): File "D:\anaconda\Scripts\jupyter-notebook-script.py", line 6, in <module> from notebook.notebookapp import main File "D:\anaconda\lib\site-packages\notebook\notebookapp.py", line 41, in <module> from jinja2 import Environment, FileSystemLoader File "D:\anaconda\lib\site-packages\jinja2\__init__.py", line 33, in <module> from jinja2.environment import Environment, Template File "D:\anaconda\lib\site-packages\jinja2\environment.py", line 15, in <module> from jinja2 import nodes File "D:\anaconda\lib\site-packages\jinja2\nodes.py", line 19, in <module> from jinja2.utils import Markup File "D:\anaconda\lib\site-packages\jinja2\utils.py", line 647, in <module> from markupsafe import Markup, escape, soft_unicode ImportError: cannot import name 'soft_unicode' from 'markupsafe' (D:\anaconda\lib\site-packages\markupsafe\__init__.py)
这个问题通常发生在更新了 anaconda 或者 jupyter notebook 后出现,可能是因为 jinja2 与 markupsafe 版本不兼容所致。你可以尝试升级 markupsafe,或者降级 jinja2 版本,具体步骤如下:
1. 在命令行中输入以下命令更新 markupsafe:`pip install --upgrade markupsafe`
2. 如果更新 markupsafe 无法解决问题,你可以尝试降级 jinja2 版本,命令如下:`pip install jinja2==2.10.1`
如果以上两种方法均不能解决问题,你可以尝试重新安装 anaconda 或 jupyter notebook。
tensorflowjs_converter Traceback (most recent call last): File "E:\ProgramFile\Anaconda\anaconda3\lib\runpy.py", line 196, in _run_module_as_main return _run_code(code, main_globals, None, File "E:\ProgramFile\Anaconda\anaconda3\lib\runpy.py", line 86, in _run_code exec(code, run_globals) File "E:\ProgramFile\Anaconda\anaconda3\Scripts\tensorflowjs_converter.exe\__main__.py", line 7, in <module> File "E:\ProgramFile\Anaconda\anaconda3\lib\site-packages\tensorflowjs\converters\converter.py", line 827, in pip_main main([' '.join(sys.argv[1:])]) File "E:\ProgramFile\Anaconda\anaconda3\lib\site-packages\tensorflowjs\converters\converter.py", line 831, in main convert(argv[0].split(' ')) File "E:\ProgramFile\Anaconda\anaconda3\lib\site-packages\tensorflowjs\converters\converter.py", line 762, in convert raise ValueError( ValueError: Missing input_path argument. For usage, use the --help flag.
这个错误提示是因为在运行 `tensorflowjs_converter` 命令时没有指定输入路径 `input_path` 参数。请尝试在命令中添加输入路径参数,例如:
```
tensorflowjs_converter --input_format=tf_saved_model /path/to/saved_model /path/to/tfjs_model
```
其中,`/path/to/saved_model` 是你的 TensorFlow SavedModel 的路径,`/path/to/tfjs_model` 是转换后输出的 TensorFlow.js 模型的路径。请根据你的实际情况修改这些路径。
阅读全文
相关推荐
![-](https://img-home.csdnimg.cn/images/20241231045053.png)
![-](https://img-home.csdnimg.cn/images/20241231045053.png)
![-](https://img-home.csdnimg.cn/images/20241231045053.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![-](https://img-home.csdnimg.cn/images/20241226111658.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)