How truong027/cnpm24 works
Smart Parking AI manages resident vehicle and parking services alongside guard-operated entry/exit and administrator oversight. In the principal gate workflow, a guard monitors vehicle imagery; Flask coordinates plate recognition and parking transactions, and MySQL stores operational state. Residents register and manage vehicles, slots, tickets, history, and transfer requests; administrators manage users, transfers, vehicle lists, parking visibility, and reports. OCR implementation and role helpers are represented as internal layers. README documents the role capabilities and intended Flask/MySQL architecture; unsampled route details are not inferred.
Main entry points: app.py Flask app · database.py MySQL access · crnn_ocr_wrapper.py CRNN wrapper · plate_ocr_integration.py OCR integration
Components 23
Gate Operations
- Gate transactions
ongthanquoctruong_24CT2_cnpm/be/app.py - Camera monitoring
ongthanquoctruong_24CT2_cnpm/be/app.py
Plate Recognition
- Plate OCR
ongthanquoctruong_24CT2_cnpm/be/app.py - CRNN wrapper
ongthanquoctruong_24CT2_cnpm/be/crnn_ocr_wrapper.py - OCR integration
ongthanquoctruong_24CT2_cnpm/be/plate_ocr_integration.py - CRNN inference
ongthanquoctruong_24CT2_cnpm/be/plate_ocr_inference.py
Resident Services
- Resident portal
ongthanquoctruong_24CT2_cnpm/fe/templates/resident_dashboard.html - Resident accounts
ongthanquoctruong_24CT2_cnpm/be/app.py - Vehicle and slot services
ongthanquoctruong_24CT2_cnpm/be/app.py - Tickets and history
ongthanquoctruong_24CT2_cnpm/be/app.py - Transfer requests
ongthanquoctruong_24CT2_cnpm/be/app.py
Administration
- Operations dashboard
ongthanquoctruong_24CT2_cnpm/public/operations-dashboard.html - User and RBAC
ongthanquoctruong_24CT2_cnpm/be/app.py - Fleet and reports
ongthanquoctruong_24CT2_cnpm/be/app.py - Parking layout setup
ongthanquoctruong_24CT2_cnpm/be/setup_bai_do.py
Application Core
- Flask app
ongthanquoctruong_24CT2_cnpm/be/app.py - MySQL access
ongthanquoctruong_24CT2_cnpm/be/database.py - Guard role
ongthanquoctruong_24CT2_cnpm/be/roles/guard_user.py - Admin role
ongthanquoctruong_24CT2_cnpm/be/roles/admin_user.py - Resident role
ongthanquoctruong_24CT2_cnpm/be/roles/resident_user.py
Other components
- Guard
- Admin
- Resident
Connections 27
- Guard → Camera monitoring: monitors
- Guard → Gate transactions: controls entry
- Camera monitoring → Flask app: sends imagery
ongthanquoctruong_24CT2_cnpm/be/app.py - Flask app → Plate OCR: dispatches recognition
ongthanquoctruong_24CT2_cnpm/be/app.py - Flask app → Gate transactions: coordinates
ongthanquoctruong_24CT2_cnpm/be/app.py - Gate transactions → MySQL access: processes transactions
ongthanquoctruong_24CT2_cnpm/be/database.py - Flask app → MySQL access: initializes
ongthanquoctruong_24CT2_cnpm/be/app.py - Flask app → CRNN wrapper: imports
ongthanquoctruong_24CT2_cnpm/be/app.py - Flask app → OCR integration: imports
ongthanquoctruong_24CT2_cnpm/be/app.py - CRNN wrapper → CRNN inference: uses inference
ongthanquoctruong_24CT2_cnpm/be/crnn_ocr_wrapper.py - OCR integration → CRNN inference: loads model
ongthanquoctruong_24CT2_cnpm/be/plate_ocr_integration.py - Resident → Resident portal: uses
- Resident portal → Flask app: uses portal routes
- Resident → Resident accounts: registers
- Resident → Vehicle and slot services: manages vehicles
- Resident → Tickets and history: views history
- Resident → Transfer requests: requests transfer
ongthanquoctruong_24CT2_cnpm/be/app.py - Admin → Operations dashboard: uses
- Operations dashboard → Flask app: uses admin routes
- Admin → User and RBAC: manages users
- Admin → Transfer requests: reviews requests
- Admin → Fleet and reports: manages fleet
- Admin → Fleet and reports: views reports
- Parking layout setup → MySQL access: seeds slots
ongthanquoctruong_24CT2_cnpm/be/setup_bai_do.py - Flask app → Guard role: imports role check
ongthanquoctruong_24CT2_cnpm/be/app.py - Flask app → Admin role: imports role check
ongthanquoctruong_24CT2_cnpm/be/app.py - Flask app → Resident role: imports role check
ongthanquoctruong_24CT2_cnpm/be/app.py