Coder Social home page Coder Social logo

zyxwvo / ai-classification Goto Github PK

View Code? Open in Web Editor NEW

This project forked from hoangsonww/ai-ml-classifiers

0.0 0.0 0.0 26.13 MB

๐ŸŒŸ This repository houses a collection of image classification models for various purposes, including vehicle, object, animal, and flower classification. Each classifier is built using deep learning techniques and pre-trained models to accurately identify and categorize images based on their respective classes.

Home Page: https://hoangsonww.github.io/AI-Classification/

License: MIT License

Python 100.00%

ai-classification's Introduction

AI Classifiers

This repository contains Python scripts for vehicle classification and object classification using pre-trained deep learning models. The vehicle classification logic uses the YOLOv3 model for vehicle detection and classification, while the object classification logic uses a pre-trained model for object classification. These scripts can be used to classify vehicles in videos and objects in images, respectively.

This repository contains two directories: one for vehicle classification logic and another for object classification logic, namely vehicle_classification and object_classification. Each directory contains the necessary files and instructions to run the respective classification logic.

Table of Contents

Vehicle Classification

Files Included

  • coco.names: Class names used for vehicle detection.
  • traffic.mp4: Sample video for vehicle detection.
  • yolov3.cfg: YOLOv3 model configuration file.
  • yolov3.weights: Pre-trained YOLOv3 model weights.
  • vehicle_detection.py: Python script for vehicle detection and classification.

Getting Started

  1. Clone the Repository

    git clone https://github.com/hoangsonww/AI-Classification.git
    cd AI-Classification/Vehicle-Classification
  2. Download Model Weights Download the pre-trained YOLOv3 model weights (yolov3.weights) from the official YOLO website or another trusted source and place it in the Vehicle-Classification directory.

  3. Install Dependencies Install the required Python dependencies.

    pip install -r requirements.txt
  4. Run Vehicle Detection Replace <video_path> in the vehicle_detection.py script with the path to your video file (traffic.mp4 or another video).

    python vehicle_detection.py

The script will then process the video frame by frame, detect vehicles, and classify them based on the detected classes. The output video will be saved as output.avi in the vehicle_classification directory.

Feel free to change the video path, output video name, and other parameters in the script to suit your needs.

Output

The output video will display the detected vehicles along with their class labels. The class labels are based on the COCO dataset, which includes various classes such as car, truck, bus, motorcycle, and bicycle.

Example output:

Vehicle Classification Output

License

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

Flower Classification

Files Included

  • flower_classification.py: Python script for flower classification.
  • daisy.jpg: Sample JPEG image for flower classification (Daisy).
  • marigold.jpg: Sample JPEG image for flower classification (Marigold).

Getting Started

Getting Started

  1. Clone the Repository

    git clone https://github.com/hoangsonww/AI-Classification.git
    cd AI-Classification/Flowers-Classification
  2. Install Dependencies Install the required Python dependencies.

    pip install -r requirements.txt
  3. Run Object Classification Replace <image_path> in the flower_classification.py script with the path to your image file (objects.jpg, objects.png, or another image).

    python flower_classification.py

Output

The output will display the class label of the flower detected in the image along with the confidence score.

Example output: Here are the sample image of Daisy flowers.

Flower Classification Output

Object Classification

Files Included

  • object_classification.py: Python script for object classification.
  • objects.jpg: Sample JPEG image for object classification.
  • objects.png: Sample PNG image for object classification.

Getting Started

  1. Clone the Repository

    git clone https://github.com/hoangsonww/AI-Classification.git
    cd AI-Classification/object_classification
  2. Install Dependencies Install the required Python dependencies.

    pip install -r requirements.txt
  3. Run Object Classification Replace <image_path> in the object_classification.py script with the path to your image file (objects.jpg, objects.png, or another image).

    python object_classification.py

The script will then classify the objects in the image and display the class labels along with the confidence scores.

Feel free to change the image path and other parameters in the script to suit your needs.

Output

The output will display the class labels of the objects detected in the image along with the confidence scores.

Object Classification Output

Animal Classification

Files Included

  • animal_classification.py: Python script for animal classification.
  • cow.jpg: Sample JPEG image for animal classification (Cow).
  • ox.jpg: Sample JPEG image for animal classification (Ox).

Getting Started

  1. Clone the Repository

    git clone https://github.com/hoangsonww/AI-Classification.git
    cd AI-Classification/Animal-Classification
  2. Install Dependencies Install the required Python dependencies.

    pip install -r requirements.txt
  3. Run Object Classification Replace <image_path> in the animal_classification.py script with the path to your image file (objects.jpg, objects.png, or another image).

    python animal_classification.py

Output

The output will display the class labels of the animals detected in the image along with the confidence scores.

Animal Classification Output

License

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

Contact Information

For any questions or issues, please contact:


ai-classification's People

Contributors

hoangsonww avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.