imagepy icon indicating copy to clipboard operation
imagepy copied to clipboard

error when windows anaconda run imagepy

Open LiangYongAI opened this issue 4 years ago • 4 comments

I create an evn named imagepy and pip install all reqired package according to requirement.txt.

(imagepy) F:\github\imagepy>python -m imagepy Traceback (most recent call last): File "d:\Anaconda3\envs\imagepy\lib\runpy.py", line 193, in run_module_as_main "main", mod_spec) File "d:\Anaconda3\envs\imagepy\lib\runpy.py", line 85, in run_code exec(code, run_globals) File "F:\github\imagepy\imagepy_main.py", line 3, in from imagepy.core.app import loader, ImagePy File "F:\github\imagepy\imagepy\core\app_init.py", line 1, in from .imagepy import ImagePy File "F:\github\imagepy\imagepy\core\app\imagepy.py", line 6, in from sciwx.canvas import CanvasNoteBook File "F:\github\imagepy\sciwx\canvas_init_.py", line 2, in from .mcanvas import MCanvas, ICanvas, VCanvas File "F:\github\imagepy\sciwx\canvas\mcanvas.py", line 4, in from .canvas import Canvas File "F:\github\imagepy\sciwx\canvas\canvas.py", line 5, in from sciapp.object import Image, Shape, mark2shp, Layer, json2shp File "F:\github\imagepy\sciapp\object_init_.py", line 1, in from .shape import * File "F:\github\imagepy\sciapp\object\shape.py", line 4, in import shapely.geometry as geom File "d:\Anaconda3\envs\imagepy\lib\site-packages\shapely\geometry_init_.py", line 4, in from .base import CAP_STYLE, JOIN_STYLE File "d:\Anaconda3\envs\imagepy\lib\site-packages\shapely\geometry\base.py", line 18, in from shapely.coords import CoordinateSequence File "d:\Anaconda3\envs\imagepy\lib\site-packages\shapely\coords.py", line 8, in from shapely.geos import lgeos File "d:\Anaconda3\envs\imagepy\lib\site-packages\shapely\geos.py", line 145, in lgeos = CDLL(os.path.join(sys.prefix, 'Library', 'bin', 'geos_c.dll')) File "d:\Anaconda3\envs\imagepy\lib\ctypes_init.py", line 348, in init self._handle = _dlopen(self._name, mode) OSError: [WinError 126] 找不到指定的模块。

LiangYongAI avatar Jun 13 '20 08:06 LiangYongAI

@yxdragon can you take a look?

LiangYongAI avatar Jun 13 '20 09:06 LiangYongAI

it seems the geos package can't be installed. You may try to install this package independently and then return to condo to install imagepy. My experience is that when I install imagepy with condo, it says that the pystackreg can't be installed and conda stoped to install imagery. I copy the pystackreg from the Pre-compiled package of imagpy (https://github.com/Image-Py/imagepy/releases) into the imagepy install direction. Then reinsitall imagepy again. Now the conda doesn't check pystackreg and successfully install imagery.

qyh405 avatar Jul 03 '20 11:07 qyh405

It is the matter of shapely, try the binary whl?

yxdragon avatar Nov 08 '20 12:11 yxdragon

缺少geos_c.dll模块,在https://www.lfd.uci.edu/~gohlke/pythonlibs/#shapely,下载对应版本的Shapely的whl文件,重装即可。 Missing geos_ c. dll, Download the corresponding version of shapely's whl file and reinstall it in https://www.lfd.uci.edu/~gohlke/pythonlibs/#shapely.

HITWenQLi avatar Nov 16 '20 03:11 HITWenQLi