I am trying to make an anaconda installation works: my problem is that the spyder3.exe in C/User/Anaconda/Script gave me an error and Spyder freezes on the launcher picture:
Unable to create process using "C:\ci\spyder_156545666\_h_env\pythonw.exe"
I am not sure of what it means: is it the path of python that is not found? Is it a specific program?
I am:
On Windows 8
Installed Python 3.8
Have pip but install and then uninstall spyder with pip
Installed Anaconda with the .exe downloaded from their webpage
If I understand the problem, I think I could fix it, but I am also interested in a direct answer.
I found a webpage with a similar problem but I don't really understand the given solution (which seems to be on Linux and using a "winpython").
Related
I've tried so many ways to fix this problem, like I've uninstall every python version I've downloaded and reinstall python 3.10.1(Although it show me that it was 3.9.10 when I check it by windows 11 cmd but VScode show me that it was 3.10.1. I have no idea that which I should trust). And I've also tried to install the module again and again(It said I've already install it). Also I can see the module was in my computer, which mean I can see it in the file. What's wrong??? If you know what's happened and you know how to fix it, please tell me! I need your suggestion to fix this stupid problem. Thanks!
It looks like you have multiple python environments and which environment you have installed the python modules was not which you have selected in the VSCode.
In the cmd execute where python to check all the python environments you have installed. In the VSCode click the python interpreter at the bottom-left on the VSCode to switch the python interpreter.
I am a complete beginner in coding.
So, I'm new to the programming jargons and processes and installations.
Please excuse me if I have misunderstood something.
I have tried to install, uninstall apps completely .. and reinstall.. and update .. Phew! It feels like a mess to me and I'm a little lost without proper direction.
And I feel that the below issues are a part of this installing, and reinstalling.
Current situation:
I tried to download Anaconda and at the end of the installation process I got an error message saying installation failed and that I had to contact the manufacturer.
But, I saw Anaconda navigator in the apps section!
I had tried to remove all the system files before reinstalling Anaconda.
How do I know if its installed properly?
Related to this: can I download/access Atom and PyCharm environments through this Anaconda navigator instead of downloading these two interpreters separately?
What does that mean to link Conda interpreter in PyCharm? How is this different?
Because when I used PyCharm previously I had issues assigning an interpreter to the PyCharm projects.
I tried to update the Python version on the Mac terminal through the Excode and Homebrew process. And during installation I got a message saying installation had failed.
But, now when I check on the bash terminal for the Python version it shows Python 3.8.8 !
How is this possible even after the error with the installation?
Now, can I uninstall Excode and Homebrew from my computer?
I have both Python 3.7 and 2.7 installed currently, and have a simple image processing script that calls for opencv. However, I keep getting the "module not found" error. I've tried using pip install, pip3 install, and installing the Windows executable from the opencv website, none of which have fixed the problem. The script won't run from either 3.7 or 2.7! I'm currently trying to use Visual Studio Code on a Windows 10 Surface computer.
Other threads seem to suggest that I need to update the Python registry/pointer or something to reflect the actual install location, but I can't seem to find how to do this. Or can I simply copy/paste the directory or files into Python directly? (Python 3.7 is preferred, or for both if possible!)
Edit: After uninstalling and reinstalling both Python 2.7 and 3.7, I think I figured out what the problem was! I was still having issues upon reinstall, so I tried rolling back a version to 3.6. During this installation, I noticed that even pip wasn't working anymore. It was at this point I realized that somehow my installation of Python was done with administrative privileges by default. Even though my account is the only one running on my personal computer, I still had to install pip with elevated privileges to get it to work. Now it seems like OpenCV and other modules are working!
I am installing python on windows10 and trying to install the opencv and numpy extentions in the command window. I get no error installing them and it says it is successfully installed. But when I try to check the installation and import cv2 it does not recognize it and give me the error: no module named cv2.
can anybody help me with this problem? Is there something wrong in installation process or do I need to install something else?
I checked the newest version of each and used the compatible one with my system.
Thanks.
One solution could be that you have 2 versions of python. So, go to the specific python's scripts directory and run: pip install numpy
If that too doesn't work, you can find the answers to this question on Why can't I import opencv3 even though the package is installed?, as stated by #Cut7er.
I have tried the solutions given to the above stated question myself also. But, they didn't work for me. So, another thing that you could try to use is this IDE called PyCharm. It ofcourse is much more beautiful that the IDLE, but it also has an inbuilt GUI controlled installation of binaries or packages. That would make things a lot easier. I have faced a lot of issues with packages for python and this IDE made things a lot easier. You can find it on https://www.jetbrains.com/pycharm/download/#section=windows.
You can also use anaconda. But, I found it a little difficult to use since, it has similar issues.
EDIT:
Seems like you are using PyCharm. But, you are installing libraries from your command prompt. So, see the answer to: ImportError: No module named 'bottle' - PyCharm. This answer guides you through how to install a certain library through your PyCharm window itself. So,
1) Go to Files>Settings
2) Search for "Interpreter" from the searching tab. Open the interpreter
3) You can now see a plus sign on the right. A click on it will open up a section on the left.
4) In the searching tab, search for numpy or opencv. Click on whichever module you want to install. And then click on the "install package" button on the bottom left. This will install the package for you.
5) Then click save. And run your file that says import cv/cv2.
This should probably do the trick.
Hope it helps!
Is it possible that you have 2 versions of python on your machine and your native pip is pointing to the other one? (e.g. you pip install opencv which installs opencv for python 2, but you are using python 3). If this is so, then use pip3 install opencv
I removed the Anaconda version on my machine, so I just have python 3.7 installed. I removed the python interpreter(Pycharm) and installed it again and the problem got fixed somehow!
I suspect you have two versions of python and the one you're using doesn't have opencv on it, because pip pointed to the wrong one.
A pragmatic solution assuming you're using the python version with conda is to just use conda to install cv2:
conda install -c menpo opencv
A more careful solution is to figure out how to get the pip that points to the python version you're using. On linux I can check that my pip points to my python like this:
:~$ which python
/home/kpierce/anaconda3/bin/python
:~$ which pip
/home/kpierce/anaconda3/bin/pip
So you see the pip and python versions are associated. On windows I suspect you do an analogous thing on the command line like
where python
where pip
And if they don't match, you might try
where python
where pip3
to see if those match. You need to use the pip that points to the correct python version. You can view the python version by entering the python interpreter and running
import sys
sys.version
For some reason I messed up my install in python a while ago and I recently tried to repair the install but I am getting an error saying: "The specified account already exists." I then decided to rerun the install package and instead of repairing it decided to delete python so I clicked uninstall and got the error message saying: "There is a problem with this Windows Installer package. A program required for this install to complete could not be run. Contact your support personnel or package vendor." The only package I installed (if it is a package) was VPython and for some reason that does not open whenever I try opening it so I assumed I messed up the download for that also. I decided to go ahead and delete everything in my C directory that had the keyword Python including the Python27 folder but it still gave me the same error.
i have same problem and i use advanced system optimizer and clean registery and repair python then uninstall and it work for me
I can confirm that this works. Use Ccleaner to fix the registry, then use installer to "Repair" 2.7.10 the installation, then use installer to "Remove" the installation.