ModuleNotFoundError: No module named 'pymatting_aot.aot' - windows

I'm on Windows and I work with python 3.8.
If I execute a python script where libraries need to be compiled, I will get the following error:
Failed to import ahead-of-time-compiled modules.
This is expected on first import.
Compiling modules and trying again.
This might take a minute.
Traceback (most recent call last):
File "C:\Users\...\env\lib\site-packages\pymatting_aot\cc.py", line 36, in <module>
import pymatting_aot.aot
ModuleNotFoundError: No module named 'pymatting_aot.aot
I already installed pymatting with pip.
Does anybody now a solution to solve this error?

Related

I cannot start Anaconda

Traceback (most recent call last):
File "/home/setsoto/anaconda3/bin/anaconda-navigator", line 7, in
from anaconda-navigator.app.main import main
ModuleNotFoundError: No module named 'anaconda_navigator'
This is what I'm getting when I try to start anaconda and I don't know what happened because it has been working fine

Cannot install enum package on Python3.6

I am trying to run this example on MacOS High Sierra. It requires installing the page package, which requires installing the pytodos package, which requires installing the enum package, installation of which fails.
$ python3 page_object_test_case.py
Traceback (most recent call last):
File "page_object_test_case.py", line 3, in <module>
import page
ModuleNotFoundError: No module named 'page'
$ pip3 install page
...
Successfully installed click-6.7 page-1.0.16
$ python3 page_object_test_case.py
Traceback (most recent call last):
File "page_object_test_case.py", line 3, in <module>
import page
File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/page/__init__.py", line 2, in <module>
from pytodos import todo
ModuleNotFoundError: No module named 'pytodos'
$ pip3 install pytodos
Collecting pytodos
...
Collecting enum==0.4.6 (from pytodos)
Downloading https://files.pythonhosted.org/packages/0c/4e/1ea357e7783c756bb579333c1e4a026fb331371ee771f616ffedc781e531/enum-0.4.6.tar.gz
Complete output from command python setup.py egg_info:
/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/setuptools/version.py:1: UserWarning: Module enum was already imported from /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/enum.py, but /private/var/folders/h3/1znktv0s36j1fdqcdrr0zvcw0000gn/T/pip-install-jhfn7vc3/enum is being added to sys.path
import pkg_resources
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/private/var/folders/h3/1znktv0s36j1fdqcdrr0zvcw0000gn/T/pip-install-jhfn7vc3/enum/setup.py", line 24, in <module>
version = main_module.__version__
AttributeError: module 'enum' has no attribute '__version__'
Note that I've tried to do the same on Ubuntu. And I had to repeat every step. However, installation of enum failed with this error instead:
AttributeError: module 'enum' has no attribute 'IntFlag'
What am I doing wrong?
You went wrong at pip install page.
You were supposed to provide your own module page.py, as described here.
pip install page pulled in some garbage and unrelated/unmaintained projects from PyPI.

Python No module named, even though the module does appear

Good day.
I've been using
pip install simplecv
to install the module simplecv.
I know the module was properly installed and when I'm printing list of the modules using
#!/usr/bin/env python2.7
import pip
installed_packages = pip.get_installed_distributions()
installed_packages_list = sorted(["%s==%s" % (i.key, i.version)
for i in installed_packages])
print(installed_packages_list)
I can see it in the list : 'simplecv==1.3'
But for some reason I can't use it.
I've tried to export the path using
1) export PYTHONPATH="/usr/local/lib/python2.7"
2) export PYTHONPATH="/usr/local/lib/python2.7/site-packages"
3) export PYTHONPATH="/usr/local/lib/python2.7/dist-packages"
But nothing works
Any ideas?
The package name isn't the same as the module name. The module is called SimpleCV, as shown in the documentation. So we have
>>> import simplecv
Traceback (most recent call last):
File "<ipython-input-2-064db77601b3>", line 1, in <module>
import simplecv
ImportError: No module named simplecv
but
>>> import SimpleCV
Traceback (most recent call last):
File "<ipython-input-3-d3da1d75bea1>", line 1, in <module>
import SimpleCV
File "/usr/local/lib/python2.7/dist-packages/SimpleCV/__init__.py", line 3, in <module>
from SimpleCV.base import *
File "/usr/local/lib/python2.7/dist-packages/SimpleCV/base.py", line 59, in <module>
raise ImportError("Cannot load OpenCV library which is required by SimpleCV")
ImportError: Cannot load OpenCV library which is required by SimpleCV
I didn't bother installing the dependencies, so this didn't work, but if I had, it would have. :-)

Python3.4.1 LINUX - from pip import main raises ImportError: Cannot import name 'main'

I'm using a server for which I am not root, and I have several scripts requiring Python 3.4.1. I built the software from the source tarball using the following syntax
$ ./configure --prefix=$HOME
$ make
$ make install
The software installed successfully, as I was able to launch python3 after modifying my .bash_profile to look in $HOME/bin. However, Pip was not so lucky.
$ pip3.4
Traceback (most recent call last):
File "/home/scnorton/bin/pip3.4", line 7, in <module>
from pip import main
ImportError: cannot import name 'main'
When I tried to run python3 get-pip.py, I get the following error:
Traceback (most recent call last):
File "get-pip.py", line 17474, in <module>
main()
File "get-pip.py", line 17466, in main
bootstrap(tmpdir=tmpdir)
File "get-pip.py", line 17406, in bootstrap
import pip
zipimport.ZipImportError: can't decompress data; zlib not available
I have checked the /usr/lib64 directory and concluded that zlib is installed on the server. I even executed the command module load zlib-1.2.8-1 and tried reinstalling pip again, with no luck. Could the problem be that Python3.4.1 is installed as a 32-bit application? If so, where can I go to get 64-bit Python3.4.1 for Linux?

Error for syncdb while installing openstack

I've seen other people say they have this error from openstack also, but I have not been able to find any kind of answer.
I followed the website http://uksysadmin.wordpress.com/2011/02/17/ for the base installation of openstack, and this seems to work correctly.
Now I'm following the website http://wiki.openstack.org/OpenStackDashboard to install openstack Dashboard and when I get to the command "tools/with_venv.sh dashboard/manage.py syncdb" I get this error:
ERROR:root:No module named local.local_settings
Traceback (most recent call last):
File "/home/harlan/horizon/openstack-dashboard/dashboard/settings.py", line 126, in <module>
from local.local_settings import *
ImportError: No module named local.local_settings
ERROR:root:No module named local.local_settings
Traceback (most recent call last):
File "/home/harlan/horizon/openstack-dashboard/dashboard/../dashboard/settings.py", line 126, in <module>
from local.local_settings import *
ImportError: No module named local.local_settings
Error: No module named horizon.dashboards.settings
I'm doing the installation on Ubuntu 11.10 Server.
It looks like it's not finding your local_settings.py file, make sure you did this step (documented on the wiki):
$ cd horizon/openstack-dashboard
$ cp local/local_settings.py.example local/local_settings.py
As an aside, the simplest way to get up and running with OpenStack is to use DevStack.

Resources