[Definitive Edition] Building an environment for learning "machine learning" using Python on Windows

Introduction

logo_horizontal.png

Many people said, "I want to study machine learning and artificial intelligence, but I'm stumbling on the environment construction before learning programming **", and I wrote an article ** to never fail in the environment construction. It was decided to do.

Currently, "** Machine Learning / Artificial Intelligence" De-Black Box "Seminar **" is being held in Tokyo, and its students We ask all of you to build a Python environment on your PC in advance. However, there were large individual differences depending on the PC, and some people failed to install. Therefore, I searched for a method that anyone could set up well, came to the conclusion of the installation method of this article, and now there are almost no people who stumble on the installation even at the seminar of about 30 people, and everyone can concentrate on the seminar. .. Therefore, I think that this article is probably the most stable installation article at the moment (2017.03.18) on Windows PC (recommended is Windows 10).

There is more than one way to build a Python machine learning environment on Windows, and you can try installing it in various ways. It's nice to have multiple methods because even if you make a mistake, you can try other methods, but ** it can be a cause for beginners to wonder which method to build the environment **.

Therefore, in this article, we are targeting the following people.

Please refer to this article to build an environment that will not fail.

Thank you for your cooperation!

If you find this article helpful, I would be grateful if you could like this article.

About the author

02.jpg

I am ** Kikagaku Co., Ltd. ** Representative Director ** Ryosuke Yoshizaki ** My name is. Currently, "** Machine Learning / Artificial Intelligence De-Black Box Seminar **" and "** Machine Learning Online Tutor ** ”is operated.

Biography

Affiliation Department / Department research content Punishment
Maizuru National College of Technology Department of Electronic Control Engineering Study image processing (AR)
Maizuru National College of Technology Department of Electrical and Control Systems Engineering Research on robotics, system control, and optimization
Kyoto University Graduate School Graduate School of Informatics (Kano Lab Appliedresearchonmachinelearningforthemanufacturingindustry ADCHEM2016BestPaperAward,ChemicalEngineeringSocietyTechnologyAward
SHIFT Inc. President's office Research on software test automation by artificial intelligence CEDEC 2016 stage
Carat Co., Ltd. Director and COO Optimal itinerary proposal app (natural language processing / optimization)
Kikagaku Co., Ltd. PresidentandCEO Machinelearning/artificialintelligenceseminarOrOnlinetutor

Kikagaku Co., Ltd.

logo_horizontal.png

Providing educational services for machine learning and artificial intelligence

We look forward to your follow-up

We provide information on machine learning and artificial intelligence from a business perspective and recommended reference books.

President and CEO Ryosuke Yoshizaki Twitter:@yoshizaki_kkgk Facebook:@ryosuke.yoshizaki Blog: Blog of Kikagaku representative

Now that the introduction is long, let's start building the environment!

Install Python and required libraries

First, go to the ** here ** page, download the ** Anaconda ** distribution file, and install it.

Anaconda will do everything from building a Python environment to installing some necessary libraries at once.

anaconda.png

22.png

It will take some time to download.

After downloading, double-click the downloaded file to execute the installation.

ana.png

2.png

Basically it is OK, but if you want to specify the location of the download file somewhere, change this location to your favorite location.

2.png

Leave the checks for "Add PATH (top)" and "Set Python installed with Anaconda as default (bottom)" to install.

Installation will be completed in a few minutes.

Why not use the official Python installation file?

スクリーンショット 2017-03-18 10.15.25.png

Of course, you can also download the installation file from the official Python page and install it.

However, with this method, when installing the library required to install the machine learning library scikit-learn called numpy or scipy depending on the PC," there is no BLAS or ATLAS "" C I often encountered difficult-to-handle errors such as "no compiler". It is very difficult to solve this, and ** Anaconda ** builds this environment in one shot, so no one has failed in building the environment.

Make sure Python and libraries are installed

Open "Windows PowerShell" (* you can also use a command prompt) that comes standard with Windows.

Enter the following command on this screen, and if it works correctly as shown below, the installation is complete.

Operation check


$ python
>>> import numpy         #Library for linear algebra
>>> import scipy         #Computer algebra library
>>> import matplotlib    #Visualization library
>>> import pandas        #Data processing library
>>> import sklearn       #Library for machine learning
>>> exit()               #Exit Python interactive mode

6.png

If there are no particular errors here, the installation is complete.

Install the library for deep learning

Open "Windows PowerShell" (* you can also use a command prompt) that comes standard with Windows.

Enter the following command on this screen to install "** Chainer **", a Python library for deep learning.

Install chainer


$ pip install chainer

6.png

pip is a very useful tool for managing Python libraries such as installing and uninstalling them. It's used a lot, so it's a good idea to remember how to use it.

Operation check

Make sure you have chainer installed using the same steps as before.

Operation check of chainer


$ python
>>> import chainer  #Loading a library for deep learning
>>> exit()          #End of interactive mode

7.png

Installation is complete if there are no particular errors as described above.

in conclusion

Thank you for building the environment on Windows. Were you able to build the environment smoothly?

I used Anaconda to install it in a very neat state, so when I needed another library in the future, I didn't see pip or this time, but if I use the conda command, Rest assured that the additional libraries will generally install successfully.

We are very much looking forward to learning machine learning and revolutionizing various industries, and we hope that this article has helped you. If you found this article useful, we would appreciate it if you could like the article.

We look forward to your follow-up

We provide information on machine learning and artificial intelligence from a business perspective and recommended reference books.

President and CEO Ryosuke Yoshizaki Twitter:@yoshizaki_kkgk Facebook:@ryosuke.yoshizaki Blog: Blog of Kikagaku representative

Until the end Thank you for reading.

Recommended Posts

[Definitive Edition] Building an environment for learning "machine learning" using Python on Windows
[Definitive Edition] Building an environment for learning "machine learning" using Python on Mac
Build an environment for machine learning using Python on MacOSX
Memo for building a machine learning environment using Python
Building an environment for "Tello_Video" on Windows
Building a Windows 7 environment for getting started with machine learning with Python
Build an interactive environment for machine learning in Python
Procedure for building a CDK environment on Windows (Python)
Let's get started with Python ~ Building an environment on Windows 10 ~
Notes for using OpenCV on Windows10 Python 3.8.3.
An introduction to Python for machine learning
Building an environment for "Tello_Video" on Raspbian
How about Anaconda for building a machine learning environment in Python?
Building an HPC learning environment using Docker Compose (C, Python, Fortran)
Building an environment for executing Python scripts (for mac)
Building an Anaconda environment for Python with pyenv
Building an environment for matplotlib + cartopy on Mac
How to build an environment for using multiple versions of Python on Mac
Install Python3 on Mac and build environment [Definitive Edition]
Building an environment for "Tello_Video" on Mac OS X
Build a machine learning Python environment on Mac OS
[Heroku] Memo for deploying Python apps using Heroku on Windows [Python]
Building an environment for natural language processing with Python
Building an environment for displaying organic compounds using RDKit
Build a machine learning environment natively on Windows 10 (x64)
Build Python environment on Windows
Build python environment on windows
Until you create a machine learning environment with Python on Windows 7 and run it
I tried to build an environment for machine learning with Python (Mac OS X)
Build a python machine learning study environment on macOS sierra
Building a Python environment on a Mac and using Jupyter lab
Python environment construction procedure memo using Docker on Windows10 Home
Building an environment to execute python programs on AWS EC2
Machine learning environment settings based on Python 3 on Mac (coexistence with Python 2)
Until building a Python development environment using pyenv on Ubuntu 20.04
Building an auto-sklearn environment that semi-automates machine learning (Mac & Docker)
Building a Python environment on Mac
I built an environment for machine learning from scratch (windows10 + Anaconda + VSCode + Tensorflow + GPU version)
Python environment construction memo on Windows 10
Anaconda python environment construction on Windows 10
Building a Python environment on Ubuntu
Install python2.7 on windows 32bit environment
[Python3] Development environment construction << Windows edition >>
<For beginners> python library <For machine learning>
Install Python development environment on Windows 10
Create a Python environment for professionals in VS Code on Windows
[Python machine learning] Recommendation of using Spyder for beginners (as of August 2020)
Example of building python development environment on windows (wsl2, vscode, pipenv)
Everything from building a Python environment to running it on Windows
Python & Machine Learning Study Memo: Environment Preparation
[Python] Building an environment with Anaconda [Mac]
Build an environment for Blender built-in Python
Python development environment for macOS using venv 2016
Python 2.7, 3.4, 3.5 extension module build environment on Windows
Notes on PyQ machine learning python grammar
Python project environment construction procedure (for windows)
Amplify images for machine learning with python
Using venv in Windows + Docker environment [Python]
Programming environment for beginners made on Windows
[50 counts] Key transmission using Python for Windows
An introduction to OpenCV for machine learning