How can I install selenium package in anaconda? - selenium

I want to know how I can install selenium package on anaconda software

Selenium may be installed through anaconda by running the following command:
conda install -c conda-forge selenium
You may find the original instructions here.
I believe that a similar question was also asked in this post, maybe you'd want to have a look.

Related

Tensorflow-Text in Miniconda

I am trying to install tensorflow-text through miniconda in Spyder. I have managed to install other modules in Spyder such as tensorflow itself, pandas, scikit-learn, etc. However, using the same command as all the other installations (with the specific package name replaced by tensorflow-text)
conda install spyder-kernels tensorflow-text -y
I continue to get the same error whenever I try to install tensorflow-text:
PackagesNotFoundError: The following packages are not available from current channels:
- tensorflow-text
followed by a suggestion to search for the package on anaconda.org. As such, I searched for the tensorflow-text package on the anaconda site and found one, albeit for linux, by rocketce. Attempting to run the commands listed under the tensorflow-text installation instructions on that webpage also yielded the same error.
At first, I tried to install tensorflow-text through pip and was able to successfully run the command
pip install -U tensorflow-text==2.10.0
which seemed to install tensorflow-text. But I could not figure out how to access it or if it was correctly installed. Specifically, I am looking to use tensorflow-text in the Spyder IDE. I was able to get tensorflow working in the IDE, but not the specific tensorflow-text.
I am using a Windows 10 system; I could not find anything on the anaconda site for Windows 10. I am rather inexperienced (if you could not already tell from the nature and description of the problem), so patience and clear explanations are appreciated. Thanks in advance!

Install TensorFlow addons

I have a venv with the following details:
python 3.6
TensorFlow 2.0.0
I tried to install tensorflow-addons using the following:
pip install -q --no-deps tensorflow-addons~=0.6
But then I keep receiving the following error:
Could not find a version that satisfies the requirement tensorflow-addons~=0.6 (from versions: )
No matching distribution found for tensorflow-addons~=0.6
You are using pip version 18.0, however version 19.3.1 is available.
You should consider upgrading via the 'python -m pip install --upgrade pip' command.
I also tried other versions of tensorflow-addons, e. g., 0.4.0, 0.5.0, ..., but it did not work out.
I came across this problem two times and each time I had to solve the problem with a different solution.
1. Solution:
Upgrade pip/pip3 by using the following command.
python3 -m pip install --upgrade pip
Select appropriate version of the tensorflow-addons using the
following link
https://github.com/tensorflow/addons#python-op-compatibility-matrix
Install using the following command
pip install tensorflow-addons==version
2. Solution:
go to https://pypi.org/project/tensorflow-addons/#history
click on appropriate version
click on "Download files" on menu to the left
click on a .whl file that matches your system
requirements/specifications
go to the directory where you download the .whl file and run the
following
pip install tensorflow_addons-name.whl
The problem appears to have been related to installing on Windows platforms in the earlier versions of tensorflow-addons. As of time of updating this comment this issue should disappear completely.
In fact the developers state it has been solved, as it is shown here:
FYI stable release for windows is out. pip install tensorflow-addons
https://github.com/tensorflow/addons/issues/173#issuecomment-573106184
At your command prompt, simply specify the version you want to install.
For me, my python version is 3.7.4 and Tensorflow version is 2.2.0
Therefore, the tensorflow-addons version that matches my python and tensorflow version is 0.10.0
pip install tensorflow-addons==0.10.0

TensorFlow on Windows: "not a supported wheel on this platform" error

Was happy to know Tensorflow is made available for Windows and we don't have to use Docker.
I tried to install as per instructions but I get this error.
pip install --upgrade https://storage.googleapis.com/tensorflow/windows/cpu/tensorflow-0.12.0rc0-cp35-cp35m-win_amd64.whl
tensorflow-0.12.0rc0-cp35-cp35m-win_amd64.whl is not a supported wheel on this platform.
What does that error mean?
I am running latest version of Python.
python --version
Python 3.5.2
This is most likely to be a 64-bit versus 32-bit issue. The pre-built TensorFlow pip package is 64-bit only, but the default version of Python 3.5.2 on Python.org is 32-bit. You can download the 64-bit release from here (select one of the "Windows x86-64" options).
It's only available for Python 3.5.x not 3.6.
You can quickly create a 3.5 environment with:
conda create -n tensorflow python=3.5
You must have a 3.5.x version of Python. The 3.6 version won't work.
If you have installed an Anaconda that contains Python 3.6, you need to downgrade its Python to 3.5.2.
Open the Anaconda Prompt as administrator, and run:
conda install python=3.5.2
After the installation is finished, you can follow the rest of the steps on tensorflow website.
Do you have Python and Anaconda installed? I had a similar issue until I uninstalled Anaconda and then the setup was fine.
I did the following steps and it worked.(Anaconda 4.4 x64)
1- Go to Windows 10 command prompt (right click and Run as admin)
2- if activated the path, you can run conda anywhere, if not, should go to .../anaconda3/scripts and run conda command from there and do the following (the main trick was to change 35 to 36)
1- conda -n tensorflow python=3.5
2- activate tensorflow
3- pip install --upgrade https://storage.googleapis.com/tensorflow/windows/cpu/tensorflow-0.12.0rc0-cp36-cp36m-win_amd64.whl
issues fixed when i did the downgrading from 3.6 to 3.5 using the below
conda install python=3.5.2
There can be two reasons:
1) You are using 32-Bit python package. Tensorflow does not support 32 bit, only 64 fit.
Check in your system settings for this. If this is fine refer to second point..
2)You are using Python 3.7.
Python 3.7 isn't eventually officially supported by Python. It's still in beta testing,
and very much under active development.
Consider downgrading to a lower version of python. For now, stick with Python 3.6 or 3.5.

How to download previous version of tensorflow?

For some reason, I want to use some previous version of tensorflow('tensorflow-**-.whl', not source code on github) and where can I download the previous version and how can I know the corresponding cuda version that is compatible.
It works for me, since I have 1.6
pip install tensorflow==1.5
Find available versions (some example results shown):
$ curl -s https://storage.googleapis.com/tensorflow |xmllint --format - |grep whl
<Key>linux/gpu/tensorflow-0.8.0-cp27-none-linux_x86_64.whl</Key>
<Key>linux/gpu/tensorflow-0.9.0-cp27-none-linux_x86_64.whl</Key>
<Key>linux/gpu/tensorflow-0.11.0-cp27-none-linux_x86_64.whl</Key>
<Key>linux/gpu/tensorflow-0.10.0-cp27-none-linux_x86_64.whl</Key>
You can, of course, filter the results further by piping through additional instances of grep.
Pick the version you want and install for Python with pip...
$ TFVERSION=linux/gpu/tensorflow-0.10.0-cp27-none-linux_x86_64.whl
$ pip install https://storage.googleapis.com/tensorflow/$(TFVERSION)
Note: cp27 in the list above indicates compatibility with Python version 2.7.
The above answer does not work any more.
You can install like this:
curl -s https://storage.googleapis.com/tensorflow |xmllint --format - |grep whl
<Key>linux/gpu/tensorflow-0.8.0-cp27-none-linux_x86_64.whl</Key>
<Key>linux/gpu/tensorflow-0.9.0-cp27-none-linux_x86_64.whl</Key>
<Key>linux/gpu/tensorflow-0.11.0-cp27-none-linux_x86_64.whl</Key>
<Key>linux/gpu/tensorflow-0.10.0-cp27-none-linux_x86_64.whl</Key>
Then pick the model you want.
Then you can run this kind of command :
# Mac OS X, CPU only, Python 2.7:
$ export TF_BINARY_URL=https://storage.googleapis.com/tensorflow/mac/cpu/tensorflow-0.11.0-py2-none-any.whl
Then install Tensorflow:
# Python 2
$ sudo pip install --upgrade $TF_BINARY_URL
# Python 3
$ sudo pip3 install --upgrade $TF_BINARY_URL
Source: https://www.tensorflow.org/versions/r0.11/get_started/os_setup#download-and-setup
You can do as suggested beforehand and search for available version in tesorflow site but you can't access versions older than available there.
So if you want an earlier version:
go to https://github.com/tensorflow/tensorflow
search for the version you want under branches - for instance r0.11
Then go to the download and setup section. Again, for r0.11: https://github.com/tensorflow/tensorflow/blob/r0.11/tensorflow/g3doc/get_started/os_setup.md and install as described there.
To download an older version of TensorFlow make sure you are using an older version of python as well. Otherwise, you will run into an issue like no version satisfying requirement found.
Create a virtual environment for this and install python==3..5
Use pip install tensorflow==1.4 or so.
Goto https://www.tensorflow.org/versions/
Click on the version you want, for example: https://www.tensorflow.org/versions/r1.1/
Click on install, for example: https://www.tensorflow.org/versions/r1.1/install/
Then follow your preferred way to install
in order to find out available previous versions all you need to do is either use :
pip search tensorflow-gpu or pip search tensorflow
conda search tensorflow-gpu or conda search tensorflow
and to install them even:
pip install tensorflow-gpu==1.15.0 or pip install tensorflow==1.15.0
conda install tensorflow-gpu==1.15.0 or conda install tensorflow==1.15.0
my experience conda search is much much cleaner and easier to find packages.
You can always download the previous version of tensorflow version
from here
Here on the top left you can change the version

Pillow installed but not identified (Mac OS Yosemite)

I Installed pillow using brew, and when I try to repeat the isntallation I see it's there:
brew install Homebrew/python/pillow
Warning: pillow-2.7.0 already installed
But when I try to load it into a script I get an error:
ImportError: No module named Image
Any suggestions?
python usually looks for Pillow under normal site package installs. Here's what I would do to get a minimal Pillow setup where python should be guaranteed to see it:
sudo easy_install pip
pip install Pillow
I think it may also be possible to just do:
sudo easy_install Pillow
but pip is a bit more user friendly if you're planning on using more python scripts that might have dependencies.
Note: another issue you might be running into is if you're trying to use the Homebrew python but are ending up using the base OSX install of it instead. Make sure which python is showing you what you expect it to be.