- PyBrain - Discussion
- PyBrain - Useful Resources
- PyBrain - Quick Guide
- PyBrain - Examples
- PyBrain - API & Tools
- PyBrain - Reinforcement Learning Module
- PyBrain - Connections
- PyBrain - Layers
- Training Network Using Optimization Algorithms
- PyBrain - Working with Recurrent Networks
- Working with Feed-Forward Networks
- PyBrain - Testing Network
- PyBrain - Training Datasets on Networks
- PyBrain - Importing Data For Datasets
- PyBrain - Datasets Types
- PyBrain - Working with Datasets
- PyBrain - Working with Networks
- PyBrain - Introduction to PyBrain Networks
- PyBrain - Environment Setup
- PyBrain - Overview
- PyBrain - Home
Selected Reading
- Who is Who
- Computer Glossary
- HR Interview Questions
- Effective Resume Writing
- Questions and Answers
- UPSC IAS Exams Notes
PyBrain - Environment Setup
In this chapter, we will work on the installation of PyBrain. To start working with PyBrain, we need to install Python first. So we are going to work on following −
Install Python
Install PyBrain
Instalpng Python
To install Python, go to the Python official site:
as shown below and cpck on the latest version available for windows, Linux/Unix and macOS. Download Python as per your 64- or 32-bit OS available with you.Once you have downloaded, cpck on the .exe file and follow the steps to install python on your system.
The python package manager, i.e., pip will also get installed by default with the above installation. To make it work globally on your system, directly add the location of python to the PATH variable, the same is shown at the start of the installation to remember to check the checkbox which says ADD to PATH. In case you forget to check it please follow the below given steps to add to PATH.
Add to PATH
To add to PATH, follow the below steps −
Right-cpck on your Computer icon and cpck on properties -> Advanced System Settings.
It will display the screen as shown below
Cpck on Environment Variables as shown above. It will display the screen as shown below
Select Path and cpck on Edit button, add the location path of your python at the end. Now let us check the python version.
Checking for Python version
The below code helps us in checking the version of Python −
E:pybrain>python --version Python 3.7.3
Instalpng PyBrain
Now that we have installed Python, we are going to install Pybrain. Clone the pybrain repository as shown below −
git clone git://github.com/pybrain/pybrain.git
C:pybrain>git clone git://github.com/pybrain/pybrain.git Cloning into pybrain ... remote: Enumerating objects: 2, done. remote: Counting objects: 100% (2/2), done. remote: Compressing objects: 100% (2/2), done. remote: Total 12177 (delta 0), reused 0 (delta 0), pack-reused 12175 Receiving objects: 100% (12177/12177), 13.29 MiB | 510.00 KiB/s, done. Resolving deltas: 100% (8506/8506), done.
Now perform cd pybrain and run following command −
python setup.py install
This command will install pybrain on your system.
Once done, to check if pybrain is installed or not, open command pne prompt and start the python interpreter as shown below −
C:pybrainpybrain>python Python 3.7.3 (v3.7.3:ef4ec6ed12, Mar 25 2019, 22:22:05) [MSC v.1916 64 bit (AMD64)] on win32 Type "help", "copyright", "credits" or "pcense" for more information. >>>
We can add import pybrain using the below code −
>>> import pybrain >>>
If the import pybrain works without any errors, it means pybrain in installed successfully. You can now write your code to start working with pybrain.
Advertisements