This project demonstrates the implementation and evaluation of two fundamental machine learning models: Linear Regression and Support Vector Machine (SVM). It includes custom implementations for educational purposes, emphasizing how these algorithms function under the hood.
.
├── main.py # Entry point for training and evaluating models
├── linear_regression.py # Linear Regression model implementation
├── svm.py # Support Vector Machine implementation
├── utils.py # Utility functions for data generation and evaluation
- Custom implementation of Linear Regression using gradient descent
- Support Vector Machine with hinge loss
- Synthetic dataset generation for binary classification
- Visualization of model performance and decision boundaries (in progress)
To install the required packages, run:
pip install numpy matplotlibRun the main script to train and evaluate both models:
python main.pyThis will:
- Generate synthetic datasets
- Train Linear Regression and SVM models
- Display evaluation metrics and decision boundaries (in progress)
- Accuracy metrics for both models
- Plots showing the classification boundaries and data distribution (in progress)
This project is open-source and available under the MIT License.
Feel free to explore and modify the models for experimentation or educational use!