Skip to content

Latest commit

 

History

History
123 lines (90 loc) · 4.28 KB

README.md

File metadata and controls

123 lines (90 loc) · 4.28 KB

WeatherPlay 🌤️🎾

GitHub Contributors GitHub License GitHub Stars

Welcome to the WeatherPlay project! This web application predicts whether it’s suitable to play a match based on weather conditions. Built with Python Flask, HTML, and CSS, it integrates a pre-trained Gaussian Naive Bayes machine learning model for accurate predictions.

🌟 Project Overview

This project demonstrates the integration of machine learning into a web application. The application uses a Gaussian Naive Bayes model to analyze weather conditions and determine match suitability. The interface is user-friendly and built with Flask for seamless interaction.

✨ Key Features

  • 🔍 Machine Learning Integration: Uses a Gaussian Naive Bayes model to predict match suitability.
  • 🌐 Multi-Page Interface: Developed with Flask, HTML, and CSS for an intuitive user experience.
  • ⚡ Real-Time Predictions: Provides immediate feedback based on user input.

🛠️ Technologies Used

  • Python: Server-side scripting and machine learning integration.
  • Flask: Web framework for handling HTTP requests and routing.
  • HTML/CSS: For structuring and styling the web pages.
  • Scikit-learn: For implementing the Gaussian Naive Bayes model.

🚀 Getting Started

Follow these steps to set up and run the project on your local machine:

📋 Prerequisites

  • Python 3.x
  • Flask
  • Scikit-learn

📥 Installation

  1. Clone the repository:

    git clone https://github.com/Priyamjain1105/WeatherPlay.git
    cd WeatherPlay
  2. Create and activate a virtual environment:

    python -m venv venv
    source venv/bin/activate  # On Windows use `venv\Scripts\activate`
  3. Install the required dependencies:

    pip install -r requirements.txt

🏃 Running The Application

  1. Start the Flask server:
    flask run
  2. Open a web browser and navigate to:
    http://localhost:5000

🖥️ Usage

  1. Enter Weather Data
    • Go to the prediction page and input the weather conditions such as temperature, humidity, and wind speed.
  2. Submit and Get Prediction
    • Click submit to receive a prediction on whether it's suitable to play a match.
  3. Explore the Interface
    • Use the navigation bar to visit different pages and access various features.

📂 Project Structure

WeatherPlay/
│
├── app.py                # Main Flask application
├── templates/            # HTML templates
│   ├── index.html        # Home page
│   ├── predict.html      # Prediction page
│   └── layout.html       # Base template
│
├── static/               # Static files (CSS, JS)
│   ├── styles.css        # Stylesheet
│
├── model/                # Pre-trained model
│   └── model.pkl         # Serialized model file
│
├── requirements.txt      # Project dependencies
└── README.md             # Project README file

📸 Screenshots

Home Page

Home Page

Prediction Page (Weather Suitable)

Prediction Suitable

Prediction Page (Weather Not Suitable)

Prediction Not Suitable

🌟 Contributors

Contributors

📄 License

This project is licensed under the MIT License - see the LICENSE file for details.

Feel free to suggest additional enhancements or provide feedback! Happy coding! 🎉