Tensorflow is an open source machine learning and deep learning platform.It was out there in 2015 and have made a good name due to its fast and good features. It can be used for multiple tasks like image classification, natural language processing, digit recognition to more complex problem. Tensorflow is becoming a great platform for both machine learning and deep learning. Previously when it was launched at that time it only supports Linux and Mac. After huge requests from developer Google has finally released the latest version r12.0 with Windows support both CPU and GPU version of Windows. As machine learning and deep learning both are resource intensive tasks, GPU support for Windows increase the performance of training large data and solving more complex problems. It also support multiple languages APIs (C++, Python & Go) also with mobile support (Android & iOS).
Let’s begin to download and setup. I will show you guys how you can download and setup Python for windows and then we will install Tensorflow on Windows.
- First step you must download and install a 64-bit version of Python >=3.5.2 remember don’t install x86 (32-bit) version.
- Download Python here
- Run the setup
3. Check add pip to Path
2. Second step, Open up command prompt and run following command for CPU version
pip install –upgrade https://storage.googleapis.com/tensorflow/windows/cpu/tensorflow-0.12.0rc0-cp35-cp35m-win_amd64.whl
For GPU version run following command
Before you hit command for GPU version few things you need to setup
- Downalod CUDA 8.0 for your Windows machine
- Download cuDNN for CUDA 8.0 here.
- Install CUDA 8.0
- Extract the cuDNN and copy the three folders ” lib, include, bin “ and past it in C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v8.0
- Now Enter the following command in command prompt
pip install --upgrade https://storage.googleapis.com/tensorflow/windows/gpu/tensorflow_gpu-0.12.0rc0-cp35-cp35m-win_amd64.whl
After entering the command, this will download Tesnorflow and required Python dependencies and install them.
Finally testing our installation, run the following code
import as tf
hello = tf.constant(‘Hello, Tensorflow on Windows!’)
sess = tf.Session()
Now you can also use Tensorflow on Visual Studio. To run it in Visual Studio follow the steps
- Create a new Python project
2. Select Python > Python Application
3. Type the above verification code
4. Run the program
If you like the article share your thoughts in comments below and don’t forget to subscribe to our newsletter for latest articles and updates.