


















Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!



















Machine learning is branch of AI that focuses on developing models and algorithms that let computers learn from data without being explicitly programmed for evry task. ML teaches system to think and understand like humans by learning from data. EXAMPLE- A child learns to recognize fruits after seeing many examples. Similarly Computer sees many images- Learn patterns- predicts correctly for new images USES Self- driving cars Financial and fraud detection Medical diagnosis Face recognition Chatbots Robots
Field Applications Healthcare Disease diagnosis, medical imaging Banking Fraud detection, loan approval, credit scoring Education Student performance prediction, personalized learning Agriculture Crop prediction, disease detection, smart irrigation E-commerce Product recommendation, price prediction Transportation Self-driving cars, traffic prediction
Social media Friend suggestions, content recommendations Cybersecurity Spam filtering, malware detection #ISSUES Poor data quality Missing values Underfitting Feature selection problems Noisy data Overfitting High computational cost Data privacy concerns
Year Scientist/Organization Development 1943 McCulloch and Pitts Proposed the first artificial neuron model 1950 Alan Turing Introduced the Turing Test for machine intelligence 1952 Arthur Samuel Developed a machine learning checkers program 1957 Frank Rosenblatt Invented the perceptron for neural networks 1967 Cover and Hart Introduced the K-Nearest Neighbors algorithm 1986 Hinton and Williams Popularized backpropagation algorithm 1997 IBM Deep Blue defeated the world chess champion 2006 Hinton’s team Developed modern deep learning techniques 2012 Geoffrey Hinton Achieved major success in image recognition 2022 OpenAI Rise of generative AI and large language models Present Modern AI systems Rapid growth in AI and machine learning applications
K-Means Clustering Hierarchical Clustering DBSCAN Principal Component Analysis #ADVANTAGES Does not need labeled data Works with large datasets Helps find hidden data patterns Useful for discovering new groups or relationships #DISADVANTAGES Less accuracy Results may need manual checking Difficult to evaluate performance Privacy concerns may occur with sensitive data #APPLICATIONS Customer segmentation Market basket analysis Image segmentation Social network analysis
Training Data Test Data Used to train the model Used to evaluate the model Model learns from this data Model accuracy is checked using this data Usually about 70% of the dataset Usually about 30% of the dataset Helps build the model Helps measure model performance Used to adjust model parameters Used for collecting results and checking generalization #Important Points
Some data is used for training and some data is used for testing. Data splitting ensures that the model is trained on one part of the dataset and tested on another part. This process checks whether the model can generalize to new examples.
Problem Statement → Data Collection → Data Cleaning → Feature Engineering ↓ Model Selection → Data Modeling → Exploratory Data Analysis ↓ AI Design → Optimization → Deployment #STEPS
Age Salary Remark 25 30000 Original record 27 40000 Original record 25 30000 Duplicate record #Action Remove duplicate rows. #HANDLING OUTLIERS ###Example [ 20,22,21,24,22, ] Here, 200 is an outlier.
It is a data transformation technique that changes numerical values to a common range, usually o to 1. #FORMULA [ x'=\frac{x-x_{min}}{x_{max}-x_{min}} ] ###Example Given: [ x=30,\quad x_{min}=10,\quad x_{max}= ] [ x'=\frac{30-10}{50-10} ] [ x'=\frac{20}{40}=0. ]
Brings values to a common range. Prevents larger values from dominating smaller values. Improves convergence in optimization-based algorithms. Useful for distance-based algorithms. #DISADVANTAGES Sensitive to outliers. If a new minimum or maximum value appears, normalized values may change.
It transforms numerical featu so that their values have a comparable scale. Important for distance and gradient based algorithms. #TYPES Method Formula Use Min-Max Scaling (x'=\frac{x-x_{min}}{x_{max}-x_{min}}) Transforms values into a fixed range Standardization/Z-score (z=\frac{x-\mu}{\sigma}) Transforms data so mean = 0 and standard deviation = 1 Robust Scaling (x'=\frac{x-\text{Median}}{IQR}) More resistant to outliers
Select feature using statistical properties of data without training model. #Examples Correlation Chi-square test Information gain #Correlation Formula [
Regularization #Regularization Formula [ L=\text{Loss}+\lambda \sum |w| ] ####L2 Regularization [ L=\text{Loss}+\lambda \sum w^ ]
Data reduction is process of reducing volumes , dimensionality or complexity of data while preserving important data. #METHODS Feature selection Feature extraction Dimensionality reduction Sampling Aggregation
It is a dimensionality reduction technique that transforms set of possibly correlated variables into a smaller set of new variables called principle components,while retaining as much variance or information. Term Meaning Variance Measures how much data varies Covariance Shows how variables change together Eigenvector Direction in transformed space Eigenvalue Amount of variance along that direction Principal Component New axis created from original features that captures maximum variance #STEPS IN PCA
Predict categories. Determine class of new data points. Use labeled data to train classification models. #TYPES OF CLASSIFICATION Type Meaning Example Binary Classification Data is divided into two possible categories Email: spam or not spam Multiclass Classification Data is divided into more than two categories Handwritten digit recognition Multi-label Classification One data item can belong to multiple categories at the same time Assigning multiple labels to one image
It is used for both classification and regression tasks. It has a hierarchial tree structure which consists of a root node, branches, internal nodes and leaf nodes. It works like a flow chart that helps in making step by step decisions. #STRUCTURE Root node: First and most important decision. Decision node: Intermediate point where a condition is checked. Leaf node: Final outcome or prediction. #EXAMPLE Attendance ≥ 75%? / Yes No / Study hours > 3? Fail / Yes No Pass Fail
Gini impurity- commonly used for classification Entropy - Measures how much uncertainty is reduced Mean squared error - commonly used for regression
It works by indentifying the k closet data points to a given input and making predictions based on the majority class or average values of those neighbours. It is also called as a lazy learner algorithm because it does not learn from training set immediately instead it store entire data set and performs computations only at time of classification. #STEPS
It tries to find the best boundary known as hyperlane that separates different classes in the data. It defines the class boundaries. The goal of SVM is to maximize the margin between two classes. This helps the model perform better on new and unseen data. Hyperplane: Decision boundary separating classes. Margin: Distance between hyperplane and support vectors. Support vectors: Data points closest to the hyperplane. #DIAGRAM Class A: ○ ○ ○ ○ ------------------------ Hyperplane × × Class B: × × Nearest points to the hyperplane = Support vectors #APPLICATIONS Image classification Face detection Text classification Handwriting recognition #TYPES OF SVM 1 LINEAR SVM Uses a linear boundary to separate data points of different classes. Assumes data is linearly separable. Hyperplane is a straight line in 2D. 2 NIN LINEAR SVM Used when data cannot be separated by a straight line. Uses kernel functions to transform data into higher-dimensional space. Handles non-linearly separable data. #ADVANTAGES AND DISADVANTAGES
Advantages Disadvantages Effective in high-dimensional datasets Can be computationally expensive for large datasets Works well when there is clear separation between classes Choosing the appropriate kernel can be difficult Useful for classification using kernels Sensitive to feature scaling
These are machine learning models that mimic complex functions of human brain. It learns patterns from data and uses those patterns to make predictions or decisions. #INPUT LAYER Receives input data. Each neuron in this layer corresponds to a feature in the input data. #HIDDEN LAYER Process input using mathematical operations. A network can have one or more hidden layers. Layers are connected using weights. #OUTPUT LAYER Produces the final output of the model. Output depends on the task, such as classification or regression. #WORKING Each connection has a weight. A neuron calculates the weighted sum of inputs and usually applies an activation function. [ z=w_1x_1+w_2x_2+\dots+w_nx_n+b ] [ output=f(z) ] Where: (x): input
###Confusion Matrix Terms Actual / Predicted Positive Negative Positive TP FN Negative FP TN Where: TP: True Positive TN: True Negative FP: False Positive FN: False Negative [ #Accuracy=\frac{TP+TN}{TP+TN+FP+FN} ] Proportion of all predictions that are correct. #Precision [ Precision=\frac{TP}{TP+FP} ] Measures how many predicted positives are actually positive. #Recall/Sensitivity [ Recall=\frac{TP}{TP+FN} ] Measures how many actual positive cases are correctly identified. #F1-Score [ F1=2\times\frac{Precision\times Recall}{Precision+Recall} ] Harmonic mean of precision and recall. #Specificity [ Specificity=\frac{TN}{TN+FP} ] Measures how well negative cases are identified. #ROC-AUC
ROC curve plots true positive rate against false positive rate. AUC summarizes the curve into a single value.
The dataset is divided into (K) clusters. Each cluster has a center called a centroid. Each data point belongs to the nearest centroid. K-Means repeats the process until stable clusters are formed. #Important Terms Term Meaning Centroid Center point of a cluster, usually calculated as the mean of points Cluster Group of data points that are similar to each other Distance Similarity measure, usually Euclidean distance #STEPS