ModuleNotFoundError: No module named 'pyttsx3' even after downloading the library - python

Even after downloading the library pyttsx3 it cannot import. It says: lmodule not found error.
I tried all the methods available as:
using pipenv
upgrading pip
But I am still dealing with same problem:

This happened to me as well, what I did is reinstall python to the newest version, once I had it I installed it using pip3 install pyttsx3, and it solved the problem for me.
(note that I'm using pip3 because I' using python3 for my project, it shouldn't cause problem to use pip but just to make sure)

Try download whl file of pyttsx3 from here.
For example download it to F:/file.
Then use pip install F:/file/pyttsx3-2.90-py3-none-any.whl to install.

The problem with pyttsx3 is that it does not work for python version 3.4,3.5,3.6
But it works for python 3.8 and above but in the documentation, it is mentioned it works woth any python above version 3+

Related

Pyglet Module not found despite being installed

I am working on an M1 Mac with Python version 3.9.7. I used pip to install pyglet (1.5.21), which worked.
However when trying to import pyglet in python scripts, the following error pops up:
ModuleNotFoundError: No module named 'pyglet'
I also tried installing pyglet version 1.5.16 using conda which results in the same error.
Other packages work just fine.
Any help is highly appreciated!
I also have M1 mac. Try using pip3 instead of pip to install pyglet. Could be you only have pip installed for python3 (which is pip3)
I was having errors with Python not finding the module/attributes - I resolved it by downloading the pyglet zip from github and saving it to the same folder that my .py file is in.

Install module in python locally

I have a very basic question. I want to install a new module on my computer in order to use it in Python (via Spyder). When I install the package via pip everything seems to work fine. When I want to import the package in my script it says that there is no module by that name (see scrennshot below)
Any suggestions what might be the problem?
Thanks a lot :)
screenshot of this problem
You're using pip3 to install.
Try installing using pip install nibabel.
Failing that, I would refer you to the following question:
Which pip is with which python?
This is a common pitfall of using different versions of Python and pip.
I think
/Applications/Spyder.app/Contents/MacOS/python -m pip install nibabel
or
/Applications/Spyder.app/Contents/MacOS/python -m pip3 install nibabel
will solve your problem
Thanks for asking the question.
Have tried conda install
Since we are in anaconda dev env.
If you are using windows
Windows: Click Start, search, or select Anaconda Prompt from the menu
and use that terminal
please find the reference
https://docs.anaconda.com/anaconda/install/verify-install/

Error "No module named pywin32" after downloading it in anaconda

I'm trying to create a module that uploads multiple files to an email using python. The method I've elected to use is found here (https://www.codeforests.com/2020/06/05/how-to-send-email-from-outlook/) which requires that you install pywin32. I tried to do the pip install, which didn't work as it was already downloaded, but I'm still having trouble getting the module to run properly. I've tried uninstalling and reinstalling, and I have it in Anaconda on both my base & spyder environments, but every time I run it (either JNB or Spdr) I get the same ModuleNotFoundError.
Thanks in advance.
So it turns out everything worked out whenever I downgraded the version of python I was using...
pip install pywin32==225
Thanks for your help, everyone!

Can't access Pandas

Hi I am having major trouble with shell.
I am not able to change the path for pip and python.
Python 3.7 is downloaded elsewhere.
Pip has an unknown path. I tried upgrading pip but it stored a blob of code and I don't know what to do with it.
Pandas not available on terminal (shell) which uses python 2.7.
Errors:
ImportError: No module named pandas
After pip install pandas I get the message: Successfully installed numpy-1.19.1 pandas-1.0.5 pytz-2020.1
I still get the message No module named pandas
please help. I have been really frustrated by this!
Have you tried pip3 install yet?
pip could default to the installation of pip for python2 as well.
Finally, if it is doable in your system, you may uninstall python 2 completely as it is out of support anyway, this would save you a lot of headache in the future!
Try
pip3 install pandas
and if that doesn't work, then try
pip install pandas
EDIT:
It sounds like you should try to run your code using python myfile.py instead of python3 myfile.py

I have installed the package from github but when importing module name not found

I'm trying to use this github repo!
but as soon as I import the package: from pykernels.basic import RBF
the following error is displayed:
ModuleNotFoundError: No module named 'basic'
I have double checked everything given my understanding of python, packages and how anaconda works but I don't know very much. The site-packages are in the path, the evn has the package and the init seems to be alright. I am really lost, if someone could tell me what I'm doing wrong or what else might be done to resolve this? Thank you!
for installation:
pip install git+https://github.com/gmum/pykernels#egg=pykernels
If you have installed both anaconda and original python, you will have two pip installed in your computer. The original python will have it's pip in \Python37\Scripts, and anaconda will have it's in \Users\admin\Anaconda3\Scripts. Your problem is that you used pip that is in \Python37\Scripts, the original pip. The original pip will install into the original python site-packages, not Anaconda's site-packages.
The solution is to make sure you're using Anaconda's pip when installing packages for use with Anaconda.

Categories