This project implements gaze detection and tracking using computer vision techniques. It processes real-time video input to identify eye contours, apply masking, reshape NumPy arrays, and run inference.
Contours.py: Extracts contours of the eyes for trackingEyeMasking.py: Applies masking techniques to isolate relevant eye regionsNumPyReshaper.py: Handles reshaping of NumPy arrays for processingrun.py: Main script to execute gaze detection and tracking
Ensure the following dependencies are installed before running the project:
dlibcv2(OpenCV)numpy
You can install the required libraries using:
pip install opencv-python numpy dlib- Ensure you have Python installed (recommended version 3.7 or later).
- Install the necessary libraries as listed above.
- Run
run.pyto start gaze detection and tracking.
python run.py- Follow on-screen instructions or refer to output for further details.
dlibrequires CMake and Boost installed for compilation if building from source.- Windows users may need to install Visual Studio Build Tools to resolve dependencies.
- Linux users should ensure
build-essentialandcmakeare installed. - If encountering installation issues, consider using pre-compiled binaries where available.
This repository contains two implementations of a Generative Adversarial Network (GAN) for generating synthetic MNIST digits.
This project implements a GAN to generate handwritten digit images using the MNIST dataset.
- The PyTorch implementation is fully functional and well-structured for ease of use.
- The TensorFlow implementation is currently incomplete and contains known bugs.
✅ PyTorch implementation works flawlessly
✅ Generates high-quality synthetic MNIST digits
✅ Modular code for better maintainability
✅ Saves model checkpoints every 5 epochs
❌ TensorFlow version is not working due to bugs
Before running the project, install the required dependencies:
pip install torch torchvision numpy matplotlibFor the TensorFlow implementation (if fixed in the future):
pip install tensorflow numpy matplotlibTraining the GAN (PyTorch) To train the model:
cd GAN_Pytorch
python train.pyCheckpoints are saved every 5 epochs in the checkpoints/ directory.
Once trained, generate images using:
python generate.pyGenerated images will be stored in the output/ directory.
Use the PyTorch implementation as it is stable and fully functional. The TensorFlow version currently contains issues and may not work correctly. If modifying or improving the TensorFlow version, ensure proper debugging before use.