Working of Machine Learning
Lets first discuss with the machine learning examples in real life :
Example: Training of students during exam.
While preparing for the exams students don’t actually cram the subject but try to learn it with complete understanding. Before the examination, they feed their machine(brain) with a good amount of high-quality data (questions and answers from different books or teachers notes or online video lectures). Actually, they train their brain with input as well as output i.e. what kind of tactic or logic do they have to solve a various kind of queries. Each time they solve practice test papers and find the performance (accuracy /score) by comparing answers with answer key given, Gradually, the performance keeps on increasing, gaining more confidence with the adopted approach. That’s how actually models are built, train machine with data (both inputs and outputs are given to model) and when the time comes test on data (with input only). Researchers are working with assiduous efforts to improve algorithms, techniques so that these models perform even much better
Basic Difference in ML and Traditional Programming?
Traditional Programming :In this we feed the DATA (Input) + PROGRAM (logic), and run the input on machine and get output.
Machine Learning :In this learning process we feed in DATA(Input) + Output and then run it on machine during training phase. The machine then creates its own program(logic), where the evaluation is done during the final phase.
What does exactly learning means for a computer?
A computer learn from Experiences with respect to some class of Tasks. if its class of tasks performance improves with the Experience then the computer is said to be in the learning phase
Hence we can say that a computer program is learning from
- Experience E with respect to some class of tasks T and
- Performance measure P, if its performance at tasks in T, as measured by P, improves with experience E
Example: while playing checkers.
E becomes the experience of playing many games of checkers
T becomes the task of playing checkers.
P becomes the probability that the program will win the next match
In general, any machine learning tasks can be categorized to one of two broad classifications:
1. Supervised learning
2. Unsupervised learning
How things work in reality:-
- Lets take an example of online shopping. In online shopping we can find millions of users with an unlimited range of interests with regards to brands, colors, price range and many more. Online shopping buyer search for a number of products and searching a product often will make buyer’s Facebook, web pages, search engine or that online store start recommending or showing offers on that particular product. There is no one sitting to write code for each and every user regarding their choice, all this task is completely automatic.
Here, machine learning plays its vital role. Data scientists, machine learners build models which fits the desire of customer and make them easy to use, on the machine using good quality. Now their machine performs huge amount of data.
In the past, the advertisement was only on newspapers, magazines and radio but now technology has made us smart enough to do Targeted advertisement (online ad system). It is a way more efficient method to target most receptive audience from the specific country
Lets take another example of machine learning in the health sector. In the health sector, ML is doing a fabulous job. Researchers and scientists have already prepared models to train machines for detecting cancer(breast cancer, brain cancer etc) just by looking at slide – cell images.
For humans to perform these task it would have taken a lot of time and also the diagnosis done by the human might not be so accurate . But now using the machine learning techniques there is no more delay and the machines predict the chances of having or not having cancer with more accuracy than doctors.
How is this all possible?
The answer to this question is very simple. It is required high computation machine, a large amount of good quality image data, ML model with good algorithms to achieve the answer to this question
Doctors are using Machine learning even to diagnose patients based on different parameters under consideration.
- You must have heard about IMDB ratings, Google Photos where it recognizes faces. Google Lens where the machine learning image-text recognition model can abstract text from the images you feed into.
Gmail which categories E-mail as social, promotion, updates using text classification, which is a part of Machine learning
How does Machine Learning works?
- Collecting past historic data in any form which is suitable for processing. The processing of the input past data is known as data pre-processing. The quality of data,determines the output model performance .
- Data Processing – Sometimes, the data we feed is in the raw form and it needs to be pre-processed. This process is called as data pre-processing phase.
Lets take an example of machine learning: A table have missing values for certain attributes. In this case, it has to be filled with suitable/appropriate values in order to perform machine learning.
Missing values for numerical attributes might be the price of the house and may be replaced with the mean value of the attribute whereas missing values for categorical attributes may be replaced with the attribute with the highest mode. This consistently depends on the types of filters we use there.
If input data is in the form of text or images then first it requires to be converted to numerical form will be required. Simply, pre-processed data is to be made appropriate and consistent. The data is to be converted into a format which is understandable by the machine
- Dividing the input data into 1.) training, cross-validation and 2.) test sets.
The ratio between training, cross validation and test sets must be 6:2:2
- Suitable algorithms and techniques should be used to build the model on the training set.
- At the last testing of our conceptualized model with data which was not fed to the model at the time of training and evaluating should be feed to determines its performance.
Pre-requisites to learn ML:
- Linear Algebra
- Graph theory
- Statistics and Probability
- Programming Skills –( Python, R, MATLAB, C++ or Octave)