Skip to content

Parth-Gochhwal/TriGuard_Anomaly

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 

Repository files navigation

🛡️ TriGuard: AI-Powered Anomaly Detection for Smart Cities

This project is a submission for the hackathon challenge to ensure data integrity in smart city environmental monitoring systems.


## 1. Problem Statement

The data from environmental sensors is the lifeblood of a smart city, but it can be manipulated. The task is to build an unsupervised machine learning model that continuously analyzes data streams from a network of sensors, learns normal operational patterns, and identifies subtle anomalies that could indicate a malfunctioning sensor or a sophisticated data tampering attack.


## 2. Our Solution - TriGuard

TriGuard is a full-stack application featuring a hybrid AI engine designed to detect a wide range of anomalies in real-time.

  • Hybrid AI Engine: Utilizes three distinct unsupervised models (Isolation Forest, Autoencoder, and LSTM Autoencoder) to detect statistical, contextual, and temporal anomalies.
  • Real-time API: A Flask backend serves the trained models and provides a live API endpoint for predictions.
  • Data Integrity: Includes a (simulated) blockchain logging feature to create a tamper-proof audit trail of detected anomalies.

## 3. Tech Stack

  • Backend: Python, Flask, Flask-CORS
  • Machine Learning: TensorFlow (Keras), Scikit-learn, Pandas
  • Frontend: React.js
  • Deployment Goal: Backend on Render, Frontend on Vercel

## 4. Project Structure

TriGuard_Final/
│
├── backend/
│   ├── models/
│   ├── app.py
│   └── requirements.txt
│
└── frontend/
    ├── src/
    ├── public/
    └── package.json

## 5. Setup and Running Instructions

### Backend Server

  1. Navigate to the backend directory:
    cd backend
  2. Install the required Python packages:
    pip install -r requirements.txt
  3. Run the Flask server:
    python app.py
    The server will be running on http://127.0.0.1:5000.

### Frontend Application

  1. Navigate to the frontend directory in a new terminal:
    cd frontend
  2. Install the required Node packages:
    npm install
  3. Run the React development server:
    npm run dev
    The application will be accessible in your browser, likely at http://localhost:5173.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors