GriaΓ eich! π This solution to the GenDev Challenge 2024 employs β¨Mixed Integer Programming.β¨
Demo: https://streaming-package-comperator.vercel.app/
(Note: This is hosted on a free tier. The first query may take up to one minute because the backend is automatically deactivated when idle.)
At the core of this application lies a mathematical model known as a Mixed Integer Program (MIP), which determines the optimal combination of streaming packages to minimize the cost of watching a given set of games. π
This mathematical model is solved using the PuLP solver in Python. π
π½οΈ Watch this video where I showcase the application and delve deeper into the implementation and future improvements.
π For those who want to dive deeper into the mathematical details, see the explanation_for_nerds.ipynb
file, which provides a detailed explanation of the underlying math.
Frontend π₯οΈ:
total_cost < maximum_cost
.Backend π οΈ:
Theory/Math π:
Ensure Python and pip are installed π.
Install the required dependencies:
cd backend
pip install -r requirements.txt
Run the Flask application π:
python app.py
The backend should now be running on http://127.0.0.1:5000
.
Ensure Node.js and npm are installed π³.
Rename example.env
to .env
:
Linux/macOS π§:
cd frontend
mv example.env .env
Windows πͺ:
cd frontend
ren example.env .env
Install the required dependencies:
npm i
Start the development server π₯:
npm run dev
The frontend should now be running on http://localhost:5173/
.