首页 / 浏览问题 / 桌面GIS / 问题详情
iDesktopx 10i 训练数据生成错误
1EXP 2022年10月16日
Python 3.6.4 |Anaconda, Inc.| (default, Jan 16 2018, 10:22:32) [MSC v.1900 64 bit (AMD64)]
[iObjectsPy]: Connection gateway-service successful, Python callback port bind 61167

Traceback (most recent call last):
  File "<input>", line 11, in <module>
  File "D:\SuperMap\SuperMap iDesktopX 10i\resources\python-helpers\pydev\_pydev_bundle\pydev_import_hook.py", line 21, in do_import
    module = self._system_import(name, *args, **kwargs)
  File "D:\BuildAgent\work\test/iobjectspy/ml\vision\__init__.py", line 1, in <module>
  File "D:\SuperMap\SuperMap iDesktopX 10i\resources\python-helpers\pydev\_pydev_bundle\pydev_import_hook.py", line 21, in do_import
    module = self._system_import(name, *args, **kwargs)
  File "D:\BuildAgent\work\test/iobjectspy/ml\vision\_datapreparation.py", line 6, in <module>
  File "D:\SuperMap\SuperMap iDesktopX 10i\resources\python-helpers\pydev\_pydev_bundle\pydev_import_hook.py", line 21, in do_import
    module = self._system_import(name, *args, **kwargs)
  File "D:\BuildAgent\work\test/iobjectspy/ml\vision\_dataprepare_collector\__init__.py", line 1, in <module>
  File "D:\SuperMap\SuperMap iDesktopX 10i\resources\python-helpers\pydev\_pydev_bundle\pydev_import_hook.py", line 21, in do_import
    module = self._system_import(name, *args, **kwargs)
  File "D:\BuildAgent\work\test/iobjectspy/ml\vision\_dataprepare_collector\object_detection_training_data.py", line 1, in <module>
  File "D:\SuperMap\SuperMap iDesktopX 10i\resources\python-helpers\pydev\_pydev_bundle\pydev_import_hook.py", line 21, in do_import
    module = self._system_import(name, *args, **kwargs)
  File "D:\BuildAgent\work\test/iobjectspy/ml\vision\_sample\create_object_detection_data_mask.py", line 16, in <module>
  File "D:\SuperMap\SuperMap iDesktopX 10i\resources\python-helpers\pydev\_pydev_bundle\pydev_import_hook.py", line 21, in do_import
    module = self._system_import(name, *args, **kwargs)
  File "D:\BuildAgent\work\test/iobjectspy/ml\toolkit\_toolkit.py", line 15, in <module>
ImportError: cannot import name 'ImageCompression'

1个回答

ImportError: cannot import name 'ImageCompression'报错提示找不到依赖模块,应该是缺少对应模块,也可能是安装的模块之间冲突导致。

建议下载的超图官网的机器学习环境包,env-cpu或env-gpu环境包,确保下载的版本与idesktopX版本一致,其次下载版本一致的resource_ml机器学习资源包。

env-cpu或env-gpu包就是一个完整的conda环境包,里面包含所需要的python三方模块,且版本均已适配。不需要额外安装模块。

在idesktopx的python环境里切换为下载的env环境包即可。
1,520EXP 2022年10月17日
...