I have been trying to install numpy using pip on Windows.
But it doesn't seem to be working.
I tried installing numpy and t told me that microsoft C++ package is missing and asked me to install it. I did that and tried re-installing numpy. But this time it doesn't seems to work. It doesn't seem to forward after this point
C:\Users\neil>pip install numpy
Collecting numpy
Using cached numpy-1.9.1.tar.gz
Running from numpy source directory.
Installing collected packages: numpy
Running setup.py install for numpy
Then I tried installing scipy, even that doesn't seem to move forward after this point.
C:\Users\neil>pip install scipy
Collecting scipy
Downloading scipy-0.14.1.tar.gz (10.9MB)
100% |################################| 10.9MB 284kB/s ta 0:00:01
You could use Anaconda. Anaconda is a completely free Python distribution (including for commercial use and redistribution). It includes over 195 of the most popular Python packages for science, math, engineering, data analysis (including numpy and scipy).
After downloading the Anaconda installer, double click on the installer application icon and run it.
Follow the instructions in the installer.
The installer is also capable of running in silent mode, without bringing up the graphical interface. To install Anaconda, type the following command into a command prompt:
> Anaconda-2.x.x-Windows-x86[_64].exe /S /D=C:\Anaconda
Good luck.
Related
I'm intermediate in python and I started learning about ML. I use qpython3 app on my android phone and as I need to use some packages such as numpy, I have to install them.
when I run the command
pip install numpy
I get an error that says that my
python version needs to be updated.
I tried many other compilers that run python 3.9 but still can't install libraries.
In Pydroid app, it requires to install an additional plugin app but I can never install it and many others have the same problem as me.
Collecting scipy
Downloading scipy-1.9.3.tar.gz (42.1 MB)
━━━━━━━━━━━━━━━━━━━━━ 42.1/42.1 MB 1.8 MB/s eta 0:00:00ERROR: Could not install packages due to an OSError: [Errno 2] No such file or directory: '/data/data/ru.iiec.pydroid3/cache/pip-unpack-ddqhn5z9/scipy-1.9.3.tar.gz'
that's the error message
I think if I find a way to install python 3.9 and run it on qpython3 it'll work
I have a pipeline using biopython. I installed a different software that also uses biopython, and it overwrote my existing biopython version to give me the latest version. Some bits of my pipeline now no longer work, I suspect because they use deprecated elements of the earlier biopython pipeline that are no longer useable.
I would therefore like to uninstall biopython and reinstall an earlier version.
When I do pip uninstall biopython, this comes up in my command prompt:
C:\Users\u03132tk>pip uninstall biopython
Uninstalling biopython-1.79:
Would remove:
c:\anaconda3\lib\site-packages\bio\*
c:\anaconda3\lib\site-packages\biopython-1.79.dist-info\*
c:\anaconda3\lib\site-packages\biosql\*
Would not remove (might be manually added):
c:\anaconda3\lib\site-packages\bio\profiler.py
c:\anaconda3\lib\site-packages\bio\~aps\__init__.py
.....many more paths
As I understand, * is a wild card. Wouldn't removing c:\anaconda3\lib\site-packages\bio\* (first removed path) remove all of the paths under Would not remove that are prefixed with c:\anaconda3\lib\site-packages\bio?
I'm just trying to clarify what it's doing.
Cheers for reading!
c:\anaconda3\lib\site-packages\bio\profiler.py
c:\anaconda3\lib\site-packages\bio\~aps\__init__.py
These files are not part of a standard biopython installation. ~aps looks odd. Possibly a previous installation was killed half-way and now your biopython installation is broken?
That being said, you are right that c:\anaconda3\lib\site-packages\bio\* would include c:\anaconda3\lib\site-packages\bio\profiler.py. The output is a little confusing here. All files listed under Would not remove (might be manually added): will be kept. Note however that for a clean biopython installation there would be no such entries:
(py39) C:\>pip install biopython
Collecting biopython
Using cached biopython-1.79-cp39-cp39-win_amd64.whl (2.3 MB)
Collecting numpy
Using cached numpy-1.23.2-cp39-cp39-win_amd64.whl (14.7 MB)
Installing collected packages: numpy, biopython
Successfully installed biopython-1.79 numpy-1.23.2
(py39) C:\>pip uninstall biopython
Found existing installation: biopython 1.79
Uninstalling biopython-1.79:
Would remove:
c:\miniconda3\envs\py39\lib\site-packages\bio\*
c:\miniconda3\envs\py39\lib\site-packages\biopython-1.79.dist-info\*
c:\miniconda3\envs\py39\lib\site-packages\biosql\*
Proceed (Y/n)? y
Successfully uninstalled biopython-1.79
(py39) C:\>
So I would suggest that after uninstalling, you just remove all remaining files in the BIO folder.
Proof that they are kept
One can reproduce the message you get by just adding a custom file in the BIO folder after installation:
(py39) C:\>pip install biopython
Collecting biopython
Using cached biopython-1.79-cp39-cp39-win_amd64.whl (2.3 MB)
Requirement already satisfied: numpy in c:\miniconda3\envs\py39\lib\site-packages (from biopython) (1.23.2)
Installing collected packages: biopython
Successfully installed biopython-1.79
(py39) C:\>type nul >> C:\miniconda3\envs\py39\lib\site-packages\Bio\profile.py
(py39) C:\>pip uninstall biopython
Found existing installation: biopython 1.79
Uninstalling biopython-1.79:
Would remove:
c:\miniconda3\envs\py39\lib\site-packages\bio\*
c:\miniconda3\envs\py39\lib\site-packages\biopython-1.79.dist-info\*
c:\miniconda3\envs\py39\lib\site-packages\biosql\*
Would not remove (might be manually added):
c:\miniconda3\envs\py39\lib\site-packages\bio\profile.py
Proceed (Y/n)? y
Successfully uninstalled biopython-1.79
(py39) C:\>dir c:\miniconda3\envs\py39\lib\site-packages\bio
Volume in drive C has no label.
Volume Serial Number is F060-053A
Directory of c:\miniconda3\envs\py39\lib\site-packages\bio
18/08/2022 15:16 <DIR> .
18/08/2022 15:16 <DIR> ..
18/08/2022 15:16 0 profile.py
1 File(s) 0 bytes
2 Dir(s) 35.953.205.248 bytes free
(py39) C:\>
Side Note
biopython is part of the anaconda distribution, so using pip install in the base env will have overwritten a package installed via conda using pip, which is bad practice and can cause inconsistencies in your environment. I would suggest modifying an anaconda base env as little as possible. Instead, you could create an environment that holds all the packages that you need for your pipeline to run stably. You can even have a .yml file specifying the required package versions so that you can easily recreate it. This has the advantage that if your experiments lead you to a broken state, you can just recreate the environment (which is a lot more of a pain for the anaconda base with >600 packages)
My tensorflow 2.0.0beta1 runs normally, but I cannot install tensorflow-text using the command pip install tensorflow-text (as described on the tensorflow page). I can find it using pip search tensorflow-text but I am getting an error
ERROR: Could not find a version that satisfies the requirement tensorflow-text (from versions: none)
There are no requirements for this package (i.e. a specific python version).
I am running on windows, using conda, python 3.6.9
Update
The first release candidate of 2.4.0 was published today which features windows wheels for the first time. 2.4.0rc0 on PyPI. Note that only wheels for Python 3.6 and 3.7 are working properly at the moment. Install via e.g.
> py -3.7 -m pip install tensorflow-text==2.4.0rc0
Original answer
At the time of writing this, tensorflow-text is not available for Windows yet.
Windows is something we do wish to add. We've had some difficulties getting a working package though, which is why it is not available yet. The difference between this library and tensorflow-probability is we make use of custom ops written in c++, and building those shared libraries to work well with Tensorflow inside Windows has had issues; plus, the lengthy build times on Windows has made iterating on these issues slow. While the next beta release (this week) will not include Windows, we would like for the next release to include it.
Source.
I'm trying to install an older version of SciPy (either 0.16.1 or 0.17.0), but when I try to use pip I get the result:
pip install scipy==0.16.1
I get the following message
Failed building wheel for scipy
So I found the .whl file here https://www.lfd.uci.edu/~gohlke/pythonlibs/#numpy but the problem is that the version here is 1.0.1, and I can't seem to find any older ones, even in the SciPy website (there are for linux and mac)
.
.
PS.
I need to use either of this versions because I'm trying to run Theano on a GPU, and the tutorial provided here http://deeplearning.net/software/theano/install_windows.html says this version is a requirement if there is any tutorial that is better and more up-to-date I would be appreciated
I want to install scikit-learn but this library needs scipy and numpy too.
I tried to add them on the setup.py but I had an error with numpy. I handle to install scikit-learn and numpy from virtenv, but I cannot install scipy.
I tried pip install scipy. The procedure finished without any problem but there isn't any scipy folder on site-packages.
Also, I tried to add only scipy on setup.py. The same as above. The procedure finished without an error but scipy isn't there.
Any help?
I don't know openshift but maybe you can adapt the work that was done to install Atlas / numpy / scipy / scikit-learn on heroku:
https://github.com/dbrgn/heroku-buildpack-python-sklearn
In particular building scipy from source (using pip) requires a fortran compiler (e.g. gfortran) which is probably not installed on OpenShift by default.
Edit: a possible alternative would be to build binary packages for numpy, scipy and scikit-learn using the wheel format and then point the pip install command to an OpenShift blob store that hosts the pre-built packages.
To make sure that the wheel package will work on OpenShift you will have to build them on the same OS (I think it's Redhat 6).
Edit #2: the manylinux1 platform tag was designed to solve this issue and makes it possible to embed the third party libraries you need inside the wheel package. There should be official numpy and scipy wheel files for x86_64 linux. In the mean time you can build them your-self by following the instructions at: https://github.com/pypa/manylinux
You will probably find more info sshing into your app ad typing tail_all.