You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

Mac系统下QGIS3.6第三方插件AVHYAS的Python依赖包安装问题问询

Mac系统下AVHYAS QGIS插件Python依赖安装步骤

你提供的插件手册中Windows依赖安装方案是基于OSGeo4W专属终端执行,Mac系统无该配套工具,可直接调用QGIS内置的Python包管理器完成安装,具体流程如下:

步骤1:获取QGIS内置Python解释器路径

  • 启动已安装AVHYAS插件的QGIS 3.6版本,点击顶部菜单栏「Plugins → Python Console」打开内置Python控制台
  • 在控制台输入如下代码,回车后即可得到当前QGIS使用的Python解释器绝对路径:
    import sys; print(sys.executable)
  • 常规dmg安装的QGIS 3.6输出路径格式通常为 /Applications/QGIS3.6.app/Contents/MacOS/bin/python3,复制该路径备用

步骤2:执行依赖安装命令

  • 打开Mac系统自带的「终端」应用
  • 按以下格式拼接安装命令:[刚才复制的Python路径] -m pip install [依赖包名],逐行执行即可完成所有依赖安装,参考命令如下(请将路径替换为你自己查询到的实际路径):
/Applications/QGIS3.6.app/Contents/MacOS/bin/python3 -m pip install scipy
/Applications/QGIS3.6.app/Contents/MacOS/bin/python3 -m pip install matplotlib
/Applications/QGIS3.6.app/Contents/MacOS/bin/python3 -m pip install scikit-image
/Applications/QGIS3.6.app/Contents/MacOS/bin/python3 -m pip install opencv-python
/Applications/QGIS3.6.app/Contents/MacOS/bin/python3 -m pip install pyproj
/Applications/QGIS3.6.app/Contents/MacOS/bin/python3 -m pip install shapely
/Applications/QGIS3.6.app/Contents/MacOS/bin/python3 -m pip install rasterio
/Applications/QGIS3.6.app/Contents/MacOS/bin/python3 -m pip install fiona
/Applications/QGIS3.6.app/Contents/MacOS/bin/python3 -m pip install geopandas
/Applications/QGIS3.6.app/Contents/MacOS/bin/python3 -m pip install earthpy
  • 若执行命令时出现权限报错,可在命令末尾添加 --user参数解决,示例:
    /Applications/QGIS3.6.app/Contents/MacOS/bin/python3 -m pip install scipy --user

步骤3:验证插件可用性

所有依赖安装完成后,完全关闭QGIS再重新启动,运行AVHYAS插件即可正常加载,不会再报依赖缺失错误。

注意事项

  • 请勿直接使用系统默认的pip3命令安装依赖,否则依赖会被安装到系统Python环境,QGIS无法识别
  • 如果你是通过Homebrew等包管理器安装的QGIS,Python路径会和dmg安装版有差异,以你在QGIS Python控制台中查询到的实际路径为准

内容的提问来源于stack exchange,提问作者user5618251

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.10.02 00:09:00