Skip to content

alexandr3i/AI-Course-Projects

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 

Repository files navigation

AI Course Projects

A collection of small AI/ML projects developed during university coursework.
Includes classical "from scratch" implementations (kNN/NN, perceptrons, hinge-loss linear classifier) and deep learning models (MNIST/Fashion-MNIST/Cats vs Dogs) using TensorFlow/Keras.


Repository Structure

All projects are inside the projects/ folder and are numbered for easy navigation:

  • 01 cifar10-knn-nn-classifier
  • 02 linear-svm-loss-classifier
  • 03 and-or-perceptron
  • 04 xor-neural-network
  • 05 handwritten-digit-recognition
  • 06 fashion-mnist-cnn-kfold
  • 07 cats-and-dogs-classification

Each project folder contains:

  • one main Python script (.py)
  • a short README.md with project-specific notes

Setup (Virtual Environment)

1) Create a virtual environment (recommended)

From the repository root:

python -m venv .venv

2) Activate it

Windows (PowerShell)
..venv\Scripts\activate

macOS / Linux
source .venv/bin/activate

3) Install dependencies

This repository uses a single requirements.txt generated via pip freeze (full environment snapshot):

pip install -r requirements.txt

Tested with: Python 3.13.7 (Windows, venv)


Running a Project

Because project folder names contain spaces, use quotes when changing directories.

  1. Go into a project folder: cd "projects/01 cifar10-knn-nn-classifier"

  2. Run the Python script inside that folder: python <script_name>.py

Repeat the same for any project, for example: cd "projects/04 xor-neural-network" python <script_name>.py

Tip: If you are unsure about the script name, open the project folder and run the only .py file inside.


Notes & Troubleshooting

TensorFlow installation issues

If tensorflow fails to install on your system (can happen depending on OS/Python version), try:

  • Python 3.11 or 3.12
  • recreate the venv and reinstall dependencies

Slow runtime (kNN / brute-force distance)

The CIFAR-10 kNN/NN project compares test images against the full training set, which can be slow.
To speed it up, reduce the evaluated subset inside the script.

External dataset required (Cats vs Dogs)

Project 07 cats-and-dogs-classification requires an external dataset:

http://tiny.cc/L6_IA_DB

Download and extract it, then update dataset paths in the script if needed.

Plot windows not showing

Some projects display training curves using matplotlib. If plots do not show:

  • try running from an IDE (PyCharm) instead of a restricted terminal
  • ensure your Python installation supports a GUI backend

Disclaimer

This repository is shared for educational purposes only.

About

A collection of university AI projects covering classic ML baselines (NN/kNN, perceptrons, linear SVM loss), ANNs, and CNN-based deep learning models (MNIST, Fashion-MNIST, Cats vs Dogs) implemented in Python with NumPy and TensorFlow/Keras.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages