Skip to content

About

All machine learning algorithms and projects

Resources

Stars

0 stars

Watchers

1 watching

Forks

Latest commit

 

History

6 Commits

Folders and files

Repository files navigation

Applied machine-learning coursework

Five single-feature regression exercises, two classification tasks and a small BERT training example. The bundled CSVs let you reproduce the tabular exercises offline.

Run the examples

Install requirements.txt in a Python 3.12 virtual environment. Each regression script loads its own CSV, plots the observations, fits a line and prompts for an input. Example:

python "Linear regression/Marks predictor.py"

For the stock examples, the final 20% of dates form the evaluation split. The model fits price against date alone. For a batch run, set MPLBACKEND=Agg and pipe an input value to the chosen script.

Classification web demo

cd Classification
waitress-serve --listen=127.0.0.1:8080 heart_disease_predictor:app

Open http://127.0.0.1:8080. The KNN pipeline fits imputation and scaling only on the training split. The form returns the predicted TenYearCHD dataset label. The CLI version also prints precision and recall. These coursework classifiers have no clinical validation. The text SVM predicts a medicine label from the training dataset and cannot establish an appropriate treatment.

Transformer example

The standalone test.py is a four-example fine-tuning demonstration. It requires PyTorch, Transformers 4.x and Accelerate. It downloads bert-base-uncased on the first run, or accepts a compatible local checkpoint via MODEL_PATH. Four training texts are sufficient to check the training loop but cannot establish sentiment-classification quality.

About

All machine learning algorithms and projects

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages