This project is a proof of concept designed to explore the capabilities of computer vision in the context of object tracking. Using OpenCV and YOLO (You Only Look Once). The implementation includes RouletteWheelTracker
and RouletteBallTracker
for tracking the roulette wheel and ball, respectively.
- Python 3.10
- Important: PyTorch must be installed before proceeding with the installation of other dependencies. Visit the official PyTorch website for detailed installation instructions.
Clone the repository to your local machine:
git clone https://github.com/cbaezp/roulette
cd roulette
After installing PyTorch, install the remaining Python dependencies:
pip install -r requirements.txt
To run the video processing script, navigate to the repository's root directory and execute:
python roulette.py
VIDEO_PATH
: Path to the input video file (e.g.,videos/roulette_test.mp4
).OUTPUT_PATH
: Path for the output video file (e.g.,output_video.mp4
).- Both,
RouletteWheelTracker
andRouletteBallTracker
have additional parameters that could be updated based on the video, angle, etc.
You can customize the behavior of the trackers by modifying their initialization parameters in roulette.py
.
Manages the video processing pipeline, handling frame reading and writing operations.
Detects and tracks the roulette wheel in video frames.
Utilizes YOLO, powered by PyTorch, for the precise tracking of the ball's position and trajectory.
This project demonstrates the practical application of computer vision techniques, showcasing object tracking under dynamic conditions.