Skip to content

TanishqSom/CAMP

Repository files navigation

CAMP - Crime Analysis and Monitoring Portal

CAMP (Crime Analysis and Monitoring Portal) is a Python-based desktop application designed to assist law enforcement agencies in efficiently managing, analyzing, and recording crime-related data. Built with PyQt5 for the GUI and integrated with MySQL, CAMP combines functionality with usability, including facial recognition-based criminal search using AI.


Mission & Vision

Our vision is to revolutionize crime analysis and case management by delivering a secure, interconnected, and intuitive software solution. CAMP aims to empower agencies with the tools needed to proactively address crimes, safeguard communities, and enhance public trust—leveraging the synergy of data and artificial intelligence.


Key Features

Police Stations Management

  • Add, view, edit, and delete station records.
  • Data includes name, location, contact, head officer, and prisoner count.

Criminals Management

  • Maintain records with fields like name, gender, DOB, DOD, case ID, keywords, photo, contact, and prison status.
  • Attach and store images securely in binary format.

Criminal Cases Management

  • Add, update, and close cases.
  • Includes case description, associated criminal ID, investigating station, status (Pending/Closed), and outcomes.

Facial Recognition (AI Integration)

  • Upload an image to match against stored criminal photos using face_recognition and OpenCV.
  • Display matched result with visual comparison and data.

User Interface

  • Intuitive, dark-themed UI built with PyQt5.
  • Smooth navigation via stacked widgets and buttons.

Database Integration

  • MySQL backend with relational schema and foreign keys.
  • Fully supports CRUD operations with error handling.

Image Processing

  • Attach images via file dialogs.
  • Convert images to and from binary format for database storage.

Executable Generation

  • Easily converted to .exe using PyInstaller for standalone deployment.

Tech Stack

Component Technology
Language Python
GUI Framework PyQt5
Database MySQL
AI Libraries OpenCV, face_recognition
Image Handling Pillow, NumPy
CLI Enhancements texttable, prettytable
Terminal Styling colorama
Packaging PyInstaller

Database Overview

Database: crime_management

Tables:

  • police_stations
    Stores police station information.

  • criminals
    Contains personal details and image data of criminals.

  • criminal_cases
    Holds case descriptions, statuses, and outcomes.

Relational mapping is ensured via foreign keys between criminals and criminal_cases.


Folder Structure


CAMP/
├── Crime\_App.py              # CLI application logic
├── gui\_app.py                # PyQt5 GUI application
├── database/
│   └── crime\_management.sql  # SQL schema (if provided)
├── assets/                   # Icons, images
├── utils/
│   └── image\_conversion.py   # Binary <-> Image conversion
├── README.md


Getting Started

Prerequisites

  • Python 3.8+
  • MySQL Server
  • MySQL Connector (mysql-connector-python)
  • Required Python libraries

Install Dependencies

pip install -r requirements.txt

Run the GUI

python gui_app.py

Run the CLI

python Crime_App.py

Image Search (Facial Recognition)

  1. Provide an image path when prompted.
  2. CAMP uses AI to extract and compare facial features.
  3. If a match is found, details are displayed with a visual side-by-side comparison.

Sample CLI Flow

***************************************
*   Crime Management System           *
***************************************
1. Add Police Station
2. Add Criminal
3. Add Criminal Case
...
9. Image Search
0. Exit

Security & Privacy

  • Images are stored in binary form within the database.
  • Face recognition is local and does not upload any user data externally.
  • Error handling in place to manage invalid or missing input securely.

Resources


Screenshots (Optional)

Add GUI screenshots, database snapshots, and sample outputs here.


Author

Tanishq Som 🔗 GitHub: Tanishq84/CAMP


License

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


CAMP stands as a testament to the powerful synergy between artificial intelligence and law enforcement, enabling safer and smarter communities.

About

CAMP (Crime Analysis and Monitoring Portal) is a Python-based desktop application built with PyQt5 and MySQL for efficient management of police stations, criminals, and criminal cases.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages