Can you guys help me with the following?
I am a beginner in programming using python 3.6 and I try to install packages like wget, pycortex, etc. In my anaconda environment, that I created in a server.
Even though these packages seem to be downloaded (typed "conda list") and imported on the command window by ipython, they can not be imported on Jupiter notebook that I start in the server. Might anyone have a thought about the reason?
Related
I have been working on a code to transfer stock data to an excel spreadsheet the code. The code works while in spyder but when I run it in CMD I get the following error message about my libraries.Error message even though clearly installed. I have everything installed in my IDE and CMD.
I've tried uninstalling and reinstalling but other than that I am completely lost. New to coding.
Type pip install pandas to install pandas module but please before installing dependencies make sure you create virtual environment for your project. So it won't contradict later on. You can use conda, virtualenv wrapper and many things as virtual environement.
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 first installed Spyder and then afterwards Python on a server (with Windows Server 2019) all on the directory "C:\Users\wi932\ .spyder-py3" and the Python folder "C:\Users\wi932\Python\Python38". Then I installed many packages (like tensorflow, matplotlib, scikitlearn) by using the command prompt of windows and pip from the directory "C:\Users\wi932\Python\Python38\Scripts" and it was okay.
However, when running Spyder I can't use the packages that I installed using pip. Whenever I run a Python programm with those modules I get an error message "ModuleNotFoundError: No module named 'tensorflow'". So the question is how can I build a "connection" between the pip and Spyder?
Does anyone have an idea? I'll appreciate every comment.
Have you considered installing anaconda?
Spyder comes as a part of this and is easy to install from the anaconda client. You can also create your base environment in the anaconda client and then switch to pip to install packages from there.
I have coded some projects in processing that I would like to continue in python under the python port p5py/p5.
I am using Anaconda as my Python environment, but couldn't find a way of installing p5py/p5 via conda; installing p5py/p5 via pip works, but the library can't be imported into within Spyder in the Anaconda environment.
I have been able to install all libraries on which p5py/p5 depends from within Anaconda, which makes it a bit frustrating that I can't get p5 installed.
I would therefore appreciate any tips for making p5py/p5 importable from with the Anaconda environment.
As performance is currently not a pressing issue to me so suboptimal workarounds would also be of help.
Today I come with a two in one set of issues that's on the verge of making me smash my computer to pieces! So please I would greatly appreciate any help as I've been stuck on it for two days now.
I have a project where osmnx is required, so I follow the install instructions provided. Which means that I created a dedicated (clean) environment for it. Within this project there is a notebook that I should run, which leads me to ImportError: No module named dotmap. So I say okay, and install dotmap in the environment through conda install.
Now heres the situation, even though I installed it sucessfully in the environment, I keep getting the same error when I run the notebook! So I think maybe I should reinstall dotmap using pip through conda prompt. But when I use pip install in the dedicated ox environment, I get failed to create process. So I say okay, lets install it again through conda install but it still doesn't work.
I see that the dotmap is being called from a main.py document. So I decide to check the main.py document by installing spyder through anaconda navigtor. Once it's installed I click launch and spyder never launches! I try to launch from the conda prompt and I just get Unable to create process using 'C:\Users\THESIS\.conda\envs\ox2\python.exe C:\Users\THESIS\.conda\envs\ox2\Scripts\spyder-script.py.
At the moment I ran out of ideas of what to do as I tried to work around it numerous times. Before questions get asked (and I hope someone asks something), I'd like to say that I already:
Reinstalled anaconda navigator
Tried created numerous environments in various different ways of installing osmnx and dotmap
Tried reinstalling and launching spyder in numerous different ways (Same thing is happening with Jupyterlab)
And probably some other things that I can not remember now off the top of my head
I know I sound fed up and angry at the moment but I just can not understand how I did not find a solution to this (what should be) simple issue.
All in all, any help is greatly appreciated!!
Following droptop recommendation, I actually just did a full clean (another one) reinstall of anaconda where I deleted almost everything that I could.
I installed it again and it's working now! Thanks for the help anyway!!
Your fresh anaconda install should have jupyter, jupyterlab and spyder in the base environment. Starting the anaconda prompt and typing in jupyter notebook should launch jupyter.
Try activating your ox2 environment with another prompt, and follow through from step 3 of this post https://medium.com/#nrk25693/how-to-add-your-conda-environment-to-your-jupyter-notebook-in-just-4-steps-abeab8b8d084