You are on page 1of 13

INDUSTRY INTERNSHIP

SUMMARY REPORT

PYTHON FOR ML/AL

BACHELOR OF TECHNOLOGY
IN
COMPUTER SCIENCE AND ENGINEERING

SUBMITTED BY
SHIVAM SINGH (20SCSE1010549)

SUBMITTED TO
MS. RATNA SINGH

Winter 2020-2021
OFFER LATER
CERTIFICATE

I hereby certify that the work which is being presented in the


internship project report entitled “ PYTHON for ML/AL” in partial
fulfilment for the award of the degree of bachelor of technology in the
school of computing science and engineering of Galgotias
University, Greater Noida is an authentic record of my own work
carried out in the industry.
To the best of my knowledge, the matter embodied in the project
report has not been submitted to any other University/ Institute for the
award of any degree

S
HIVAM SINGH
(20SCSE1010549)

This is to certify that the above statement made by the candidate is


correct and true to the best of my knowledge.
Signature of Internship Coordinator Signature of
Dean(SCSE)

Dr. N. Partheeban Dr. Munish


Sabharwal
Professor & IIIC Professor & Dean
School of Computing Science & School of Computing
Science & Enginnering
Enginnering Galgotias University
Galgotias University Greater Noida
Greater Noida
ABSTRACT

Artificial Intelligence and Machine Learning are the buzzwords that


have been able to grasp the interest of many researchers since various
numbers of years. Enabling computers to think, decide and act like
humans has been one of the most significant and noteworthy
developments in the field of computer science. Various algorithms
have been designed over time to make machines impersonate the
human brain and many programming languages have been used to
implement those algorithms. Python is one such programming
language that provides a rich library of modules and packages for use
in scientific computing and machine learning. This paper aims at
exploring the basic concepts related to machine learning and attempts
to implement a few of its applications using python. This paper
majorly used Scikit-Learn library of Python for implementing the
applications developed for the purpose of research.
INTRODUCTION
Machine learning is a type of artificial intelligence (AI) that provides
computers with the ability to learn without being explicitly
programmed. Machine learning focuses on the development of
Computer Programs that can change when exposed to new data. In
this article, we’ll see basics of Machine Learning, and
implementation of a simple machine learning algorithm using
python.
 
Setting up the environment
Python community has developed many modules to help
programmers implement machine learning. In this article, we will be
using numpy, scipy and scikit-learn modules. We can install them
using cmd command: 
 

pip install numpy scipy scikit-learn


A better option would be downloading miniconda or anaconda
packages for python, which come prebundled with these packages.
Follow the instructions given here to use anaconda. 

Features and Advantages of Python

Python is an Interpreted language which in lay man’s terms means


that it does not need to be compiled into machine language instruction
before execution and can be used by the developer directly to run the
program. This makes it comprehensive enough for the language to be
interpreted by an emulator or a virtual machine on top of the native
machine language which is what the hardware understands.

It is a High-Level Programing language and can be used for


complicated scenarios. High-level languages deal with variables,
arrays, objects, complex arithmetic or Boolean expressions, and other
abstract computer science concepts to make it more comprehensive
thereby exponentially increasing its usability.

Python is also a General-purpose programming language which


means it can be used across domains and technologies.

Python also features dynamic type system and automatic memory


management supporting a wide variety of programming paradigms
including object-oriented, imperative, functional and procedural to
name a few.

Python is available for all Operating Systems and also has an open-
source offering titled CPython which is garnering widespread
popularity as well.

Let us now look as to how using Python for Artificial Inelegance


gives us an edge over other popular programming languages.

AI and Python: Why?

The obvious question that we need to encounter at this point is why


we should choose Python for AI over others.

Python offers the least code among others and is in fact 1/5 the
number compared to other OOP languages. No wonder it is one of the
most popular in the market today.

 Python has Prebuilt Libraries like Numpy for scientific


computation, Scipy for advanced computing and Pybrain for
machine learning (Python Machine Learning) making it one of
the best languages For AI.
 Python developers around the world provide comprehensive
support and assistance via forums and tutorials making the job
of the coder easier than any other popular languages.
 Python is platform Independent and is hence one of the most
flexible and popular choiceS for use across different platforms
and technologies with the least tweaks in basic coding.
 Python is the most flexible of all others with options to choose
between OOPs approach and scripting. You can also use IDE
itself to check for most codes and is a boon for developers
struggling with different algorithms

AI and Python: Why?

The obvious question that we need to encounter at this point is why


we should choose Python for AI over others.

Python offers the least code among others and is in fact 1/5 the
number compared to other OOP languages. No wonder it is one of the
most popular in the market today.

 Python has Prebuilt Libraries like Numpy for scientific


computation, Scipy for advanced computing and Pybrain for
machine learning (Python Machine Learning) making it one of
the best languages For AI.
 Python developers around the world provide comprehensive
support and assistance via forums and tutorials making the job
of the coder easier than any other popular languages.
 Python is platform Independent and is hence one of the most
flexible and popular choiceS for use across different platforms
and technologies with the least tweaks in basic coding.
 Python is the most flexible of all others with options to choose
between OOPs approach and scripting. You can also use IDE
itself to check for most codes and is a boon for developers
struggling with different algorithms.

Decoding Python alongside AI


Python along with packages like NumPy, scikit-learn, iPython
Notebook, and matplotlib form the basis to start your AI project.

NumPy is used as a container for generic data comprising of an N-


dimensional array object, tools for integrating C/C++ code, Fourier
transform, random number capabilities, and other functions.

Another useful library is pandas, an open source library that provides


users with easy-to-use data structures and analytic tools for Python.

Matplotlib is another service which is a 2D plotting library creating


publication quality figures. You can use matplotlib to up to 6
graphical users interface toolkits, web application servers, and Python
scripts.

Your next step will be to explore k-means clustering and also gather
knowledge about decision trees, continuous numeric prediction,
logistic regression, etc.

Some of the most commonly used Python AI libraries are AIMA,


pyDatalog, SimpleAI, EasyAi, etc. There are also Python libraries for
machine learning like PyBrain, MDP, scikit, PyML.

Let us look a little more in detail about the various Python libraries in
AI and why this programming language is used for AI.

Python Libraries for General AI

 AIMA – Python implementation of algorithms from Russell and


Norvig’s ‘Artificial Intelligence: A Modern Approach.’
 pyDatalog – Logic Programming engine in Python
 SimpleAI – Python implementation of many of the artificial
intelligence algorithms described on the book “Artificial
Intelligence, a Modern Approach”. It focuses on providing an
easy to use, well documented and tested library.
 EasyAI – Simple Python engine for two-players games with AI
(Negamax, transposition tables, game solving).

Python for Machine Language (ML)

Let us look as to why Python is used for Machine Learning and the
various libraries it offers for the purpose.

 PyBrain –  A flexible, simple yet effective algorithm for ML


tasks. It is also a modular Machine Learning Library for Python
providing a variety of predefined environments to test and
compare algorithms.
 PyML – A bilateral framework written in Python that focuses
on SVMs and other kernel methods. It is supported on Linux
and Mac OS X.
 Scikit-learn – Scikit-learn is an efficient tool for data analysis
while using Python. It is open source and the most popular
general purpose machine learning library.
 MDP-Toolkit – Another Python data processing framework that
can be easily expanded, it also has a collection of supervised and
unsupervised learning algorithms and other data processing
units that can be combined into data processing sequences and
more complex feed-forward network architectures. The
implementation of new algorithms is easy and intuitive. The
base of available algorithms is steadily increasing and includes
signal processing methods (Principal Component Analysis,
Independent Component Analysis, and Slow Feature Analysis),
manifold learning methods ([Hessian] Locally Linear
Embedding), several classifiers, probabilistic methods (Factor
Analysis, RBM), data pre-processing methods, and many others.
Python Libraries for Natural Language & Text Processing

 NLTK – Open source Python modules, linguistic data and


documentation for research and development in natural
language processing and text analytics with distributions for
Windows, Mac OSX, and Linux.

Python over other popular languages

Let us now see where Python stands with another computer language
for AI like C++ and Java.

Conclusion
Python plays a vital role in AI coding language by providing it with
good frameworks like scikit-learn: machine learning in Python, which
fulfils almost every need in this field and D3.js – Data-Driven
Documents in JS, which is one of the most powerful and easy-to-use
tools for visualisation.

Other than frameworks, its fast prototyping makes it an important


language not to be ignored. AI needs a lot of research, and hence it is
necessary not to require a 500 KB boilerplate code in Java to test a
new hypothesis, which will never finish the project. In Python, almost
every idea can be quickly validated through 20-30 lines of code (same
for JS with libs). Therefore, it is a pretty useful language for the sake
of AI.

Thus it is quite evident that Python is the best AI Programming


Language under the sun. Apart from being the best language for
artificial intelligence, Python is useful for many other objectives
REFERENCES

 https://www.geeksforgeeks.org/
 https://www.cuelogic.com/

You might also like