MKO — Portfolio
Mohamed Karim OuertataniIngénieur Full-StackFull-Stack Engineer
IoTWeb

NoorCity

Smart Street Lighting

February 2025 – May 2025 · Team project · ESPRIT

0views
NoorCity

A Symfony web platform to supervise the street lighting of a connected city: geolocated street lights on a map, IoT sensors, traffic cameras, energy, citizen complaints and interventions, with new locations suggested by machine learning (K-Means).

By the numbers

0

routes (approx.)

0

Doctrine entities

0

Twig views (approx.)

0

external APIs integrated

Case study

The challenge

A city's lighting network is often managed with separate tools: a plan, consumption readings, breakdown reports and interventions. The goal was to bring it all onto a map, link each street light to its sensors and cameras, and automate the alerts.

Architecture

Interfaces

  • MaterialPro back office (Twig, Bootstrap)
  • SmartLamp citizen front office
  • Leaflet + OpenStreetMap maps

Symfony 6.4

  • 12 controllers, ~75 routes
  • 17 Doctrine entities
  • Role-based dynamic forms
  • SMS, e-mail and assistant services

Data & scripts

  • MySQL (17 tables)
  • Python: K-Means, QR codes
  • HTTP IoT gateway (JSON)

External services

  • Twilio (SMS)
  • Mailjet (e-mail)
  • OpenCage (geocoding)
  • OpenStreetMap

Technical choices

01

Machine learning in a PHP app

Symfony writes the data as JSON, runs the Python K-Means script and reads the result back: new street light locations are suggested right on the map.

02

Decision support

The energy profile comparator normalizes consumption, cost and active time, then computes a weighted score from the chosen weights (100 % in total).

03

Automatic alerts

A temperature above 50 °C triggers a Twilio SMS, so does a new energy source, and every new profile sends an e-mail through Mailjet.

04

Reliable data

Validation constraints on the entities (IP address, stream URL, measurement ranges), PHP 8.1 enums mapped to Doctrine and CSRF protection on deletions.

Key features

  • Interactive Leaflet map of zones and street lights (green when working, red when broken), placing a light by clicking the map with OpenCage geocoding
  • New street light locations suggested by K-Means (scikit-learn), run from Symfony
  • IoT sensors (temperature, light, motion, consumption): dashboard, multi-criteria search, Excel export and a QR code per sensor
  • Automatic SMS alert (Twilio) above 50 °C, e-mail notifications (Mailjet) when a profile is created
  • A “Sensors Pro” assistant that queries the database: broken sensors, averages by type, anomaly detection
  • Multi-criteria energy profile comparator: a weight per criterion, normalized values and a weighted score
  • IP cameras: live stream from a street light and traffic analysis by a Python script
  • Citizen complaints on a public front office, then interventions assigned to technicians; PDF, Excel and CSV exports

Screenshots (20)

NoorCity — Smart Street Lighting — Screenshots 1
1/20

A word about this project

A question, an opinion, an idea?

Write to me right from here. Your message is not published: I am the only one who reads it.

Private: never shown on the site