Skip to content
This repository has been archived by the owner on Apr 24, 2023. It is now read-only.

ModuleNotFoundError: No module named 'shapely' #9

Open
sepastian opened this issue Feb 9, 2021 · 1 comment
Open

ModuleNotFoundError: No module named 'shapely' #9

sepastian opened this issue Feb 9, 2021 · 1 comment

Comments

@sepastian
Copy link

First off, thanks for origami, this looks promising and useful!

I'm following the installation instructions in README.md.

I am not using conda but asdf, so I skipped:

conda create --name origami python=3.7 -c defaults -c conda-forge --file origami/requirements/conda.txt
conda activate origami

and directly installed requirements with PIP:

# Install requirements.
pip install -v -r requirements/pip.txt 

I then try to give origami a first try with, which results in an error:

cd /path/to/origami
python -m origami.batch.detect.segment
Traceback (most recent call last):
  File "/home/sebastian/.asdf/installs/python/3.7.2/lib/python3.7/runpy.py", line 193, in _run_module_as_main
    "__main__", mod_spec)
  File "/home/sebastian/.asdf/installs/python/3.7.2/lib/python3.7/runpy.py", line 85, in _run_code
    exec(code, run_globals)
  File "/home/sebastian/Code/origami/origami/batch/detect/segment.py", line 7, in <module>
    from origami.core.segment import SegmentationPredictor
  File "/home/sebastian/Code/origami/origami/core/segment.py", line 9, in <module>
    from origami.core.page import Page, Annotations
  File "/home/sebastian/Code/origami/origami/core/page.py", line 6, in <module>
    import shapely
ModuleNotFoundError: No module named 'shapely'

To fix this, installed shapely with:

pip install shapely

Shapely should be added to requirements.txt.

@poke1024
Copy link
Owner

poke1024 commented Feb 9, 2021

To get all necessary packages when using only pip you should try

pip install -v -r requirements/pip.txt 
pip install -v -r requirements/conda.txt 

...yes, the naming is not ideal.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants