pmelchior / scarlet

hyperspectral galaxy modeling and deblending
MIT License
49 stars 22 forks source link

ModuleNotFoundError: No module named 'scarlet.operators_pybind11' #266

Closed silkerice closed 2 years ago

silkerice commented 2 years ago

Hi!

When trying to import scarlet I get the following error:

ModuleNotFoundError: No module named 'scarlet.operators_pybind11'

I did install pybind11, and when I open the scarlet file I do see the operators_pybind11.cc, so I don't understand what's going on. Can somebody help me with this?

Kind regards,

Silke

herjy commented 2 years ago

That is a very common issue referenced here #251 . We need to find a way to make the error more explicit as to how to avoid it. Sorry about that. If you are importing scarlet from within the repo, please try instead to import it from a different repo/location.

silkerice commented 2 years ago

Thank you for responding so quickly! I'm not running scarlet from within the repo. I also updated libgcc. I'm using python 3.9.5 and git version 1.8.3.1. Do you know what else could be going wrong?

pmelchior commented 2 years ago

If you are not running from within the repo (which, as Remy pointed out, you shouldn't), how did you install in? Do you get any errors during the setup process?

silkerice commented 2 years ago

I followed the installation guide: https://pmelchior.github.io/scarlet/install.html . I didn't get any errors in the setup process.

pmelchior commented 2 years ago

What platform are you on?

silkerice commented 2 years ago

Hi! Sorry for the late response. I'm using a Linux OS, with miniconda and I'm running the program in Jupyter lab.

pmelchior commented 2 years ago

OK, that's all standard. I assume your python is also recent (>=3.7). If so, please rerun python setup.py install and check carefully if there are errors during the compilation and install.

herjy commented 2 years ago

@silkerice would you mind posting what fixed your issue for future reference? Thanks.

silkerice commented 2 years ago

I don't know what caused the issue at first, but because of the installing/re-installing the path to the module lead to an empty directory. After changing the path everything worked smoothly again.