Artificial Intelligence & Machine Learning: Practical Training Report
Artificial Intelligence & Machine Learning: Practical Training Report
Degree
of
BACHELOR OF TECHNOLOGY
In
In this project we were asked to experiment with a real world dataset and to
Explore how machine learning algorithms can be used to find the patterns in
data.
CONTENTS
Features of Python :
1. Simple and easy to learn
2. Free and open source.
3. General Purpose and high level programming language.
4. Platform independent.
5. Case Sensitive.
6. Interpreted Language.
7. Dynamically typed.
8. Rich Library.
9. We can write concise code using python.
Applications :
1. Desktop Applications (Calculator, Notepad, etc..)
2. Web Applications (YouTube, Dropbox, Google, Instagram, Quora, Spotify)
3. Scientific and Numeric Computing (Scipy, Numpy)
4. Database Applications (Library Management Systems, Pharmaceutical)
5. Network Applications
6. Developing Games (Battlefield, Sims 4, PUBG)
7. Data Science (Pandas, Matplotlib, Seaborn, etc)
8. Machine Learning
9. AI
10. IOT
Identifiers :
Rules to define identifiers :
1. Allowed characters → Alphabets, Digits and Underscore Symbol
2. Identifier should never start with a digit
3. Case Sensitive.
4. No length limit.
5. Can't use reserved words for identifier.
Data Types :
Numeric - int, float, complex (Immutable)
Boolean - bool (True/False)
Strings (Immutable)
List (Mutable, mostly used to store homogeneous data types)
Tuple (Immutable, faster compared to List)
Set (Unordered collection of items, mutable, removes duplicates)
Dictionary (Unordered collection of Key-Value Pairs, Mutable, Keys are
Unique - values may not be unique)
Comments :
# This is a single line comment
'''
this is a
multiline comment - 1
'''
"""
this is a
multiline comment - 2
"""
Here are some problem statements:
Q.1: Write a program to get a user input in the form of a list data type.
Return a list by removing all the duplicates.
a =[]
num = int(input(" enter the total number of elements in list :"))
for x in range (0,num):
a.append(int(input("enter the element " +
str(x+1) +":")))
b=set()
non_duplicate = []
for x in a:
if x not in b:
non_duplicate.append(x)
b.add(x)
print("so , non duplicate elements are: ")
print(non_duplicate)
OUTPUT:
enter the total number of elements in list :5
enter the element 1:1
enter the element 2:2
enter the element 3:3
enter the element 4:3
enter the element 5:3
so , non duplicate elements are:
[1, 2, 3]
Q.2: Write a program to create a user defined tuple with 'int' data type
and perform the following operations
a =[]
bum = int(input(" enter the total number of elements in list :"))
for x in range (0,bum):
a.append(int(input("enter the element " +
str(x+1) +" : ")))
a = tuple(a)
print(type(a))
print("length of tuples : " , len(a))
print("sum of all the elements : " , sum(a))
print("largest element : " ,max(a))
print("smallest element : ", min(a))
OUTPUT
enter the total number of elements in list :2
enter the element 1 : 1
enter the element 2 : 2
<class 'tuple'>
length of tuples : 2
Q.2: Write a program to create a user defined tuple with 'int' data type
and perform the following operations
a =[]
bum = int(input(" enter the total number of elements in list :"))
for x in range (0,bum):
a.append(int(input("enter the element " +
str(x+1) +" : ")))
a = tuple(a)
print(type(a))
print("length of tuples : " , len(a))
print("sum of all the elements : " , sum(a))
print("largest element : " ,max(a))
print("smallest element : ", min(a))
OUTPUT
sum of all the elements : 3
largest element : 2
smallest element : 1
Margins : 1” on top, bottom & right, 1.25” on left.
Page Nos. : Bottom right corner starting from Chapter 1 to end
Text Font : Time New Roman
Main Body : 12 pts, 1.5 spacing with 0.5” paragraph margin and
one blank line between all paragraphs and between
titles/subtitles and paragraphs
Headings - : Left Justified, 14 Pts, Bold Face, Title Case with Section Nos., Chapter
wise.
Sub Headings-: Left Justified, 12 Pts, Bold Face, and Title Case with Section Nos.
Figure Captions:
Figure – Chapter No. Figure No. – Name of Figure
(Bold Face, Title Case, Centered, 10 Pts. at the bottom of Figures)
Table Captions:
Table – Chapter No. Table No. – Name
(Bold Face, Title Case, Centered, 10 Pts. at the top of Table)