Skip to content

This project combines machine learning and robotics simulation to create a system capable of object detection and interaction within a simulated environment. Using TensorFlow for the AI model and PyBullet for the simulation, the project demonstrates how a robot can be trained to recognize objects and respond accordingly.

License

Notifications You must be signed in to change notification settings

bniladridas/SimuBot

Repository files navigation

ML Project

Python TensorFlow PyBullet

This project uses machine learning for object detection and simulates a robot using PyBullet.

Installation

Follow these steps to set up the project:

# Clone the repository
git clone https://github.com/bniladridas/SimuBot.git

# Navigate to the project directory
cd SimuBot

# Install dependencies
pip install -r requirements.txt

Usage

Instructions on how to use the project:

# Run the simulation
python src/main.py

Project Structure

  • src/: Contains the source code for the simulation and AI components.
    • simulation.py: Sets up and runs the simulation.
    • ai.py: Contains the AI model and feature extraction code.
    • utils.py: Utility functions for image preprocessing.
    • main.py: Main entry point for running the simulation and AI tasks.
  • assets/: Contains URDF files for the robot and plane.
  • models/: Contains the pre-trained AI models.
  • img/: Contains sample images for testing.

License

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

ML Workflow

Control Flow Diagram

This diagram illustrates the control flow of the ML component for object detection:

flowchart TD
    A[Start] --> B[Load Image]
    B --> C{Preprocess Image?}
    C -->|Yes| D[Resize Image]
    D --> E[Normalize Image]
    E --> F[Add Batch Dimension]
    F --> G[Feature Extraction]
    G --> H[Model Prediction]
    H --> I[Output Features]
    I --> J[End]
    C -->|No| G
Loading

Model and Algorithm Diagram

Here's an overview of the model architecture and algorithms used:

classDiagram
    class Model {
        +MobileNetV2 model
        +load_model(model_path: str)
        +predict(input_data: Tensor)
    }

    class ImageProcessing {
        +preprocess_image(image: np.array)
        +extract_features(image_path: str)
    }

    class Simulation {
        +setup_simulation()
        +run_simulation(physicsClient)
    }

    Model -- ImageProcessing : Uses
    ImageProcessing -- Simulation : Provides features for
Loading

Explanation

  • Model: The project leverages a pre-trained MobileNetV2 for object detection, loaded using TensorFlow's Keras API.
  • Image Processing: Images are preprocessed (resized, normalized) before being fed into the model for feature extraction.
  • Simulation: The extracted features could guide actions within the PyBullet simulation environment, simulating real-world scenarios where object detection informs robot behavior.

About

This project combines machine learning and robotics simulation to create a system capable of object detection and interaction within a simulated environment. Using TensorFlow for the AI model and PyBullet for the simulation, the project demonstrates how a robot can be trained to recognize objects and respond accordingly.

Topics

Resources

License

Stars

Watchers

Forks

Languages