Problem Statement

  • Whether it be searching for empty spaces in Haram or Masjid e Nabvi for praying
  • Whether it be managing crowd at Mina Arafat Muzdalifa
  • Its been a real pain to effectively utilize the complete space and redirect pilgrims to correct areas
  • What time is best suited for Tawaf or to visit any specific area

Challenges covered

  • Manage crowd and motivate visitors to participate in the Hajj safely.
  • Simulating crowd movement planning for evacuation and forecasting of accidents and hazards.
  • Multiple languages
  • Automate Crowd Management process


  • Cameras are already placed mostly every where
  • Capturing human presence using cameras and using the result to color code areas showing crowd density
  • After every minute camera snap will be sent to Google Cloud vision API for face detection.
  • Based on previously defined user per area limit threshold for every camera and face detection results we will color code the area on the area map.
  • Green for open, yellow for still space left, orange for almost filled and red for completely filled
  • ML to predict stampede detection and chaos areas

Web Admin Panel

  • An admin representative will be able to see real time crowd status for every area on the portal
  • Mark Areas as 'closed for public'and do a redirection just before the area is red.
  • Add cameras and mark thresholds for each area
  • View today's status
  • View comparative crowd stats for a venue (Last year, Last month)
  • Add admin accounts

Android, iOS app for User

  • Lets suppose a user wants to perform Tawaf on the ground floor. He opens his app to see the color coded current crowd status of Mataf. Results will be personalized based on his selected Language.This would save his time and energy and direct him to the right place.
  • A user can also get personalized notification for happy hours at their favorite places.

Display Units outside gates

  • If some user doesn't have a smart phone. There can be LCD placed on gates to show the same status on LCDS which may switch in different languages after specific time intervals.

Learning and Prediction

  • We save the results each day and then using Machine Learning and deep learning we prepare a backup plan for future.
  • Using the past results the system can predict the peak hours, happy hours. For eg. that on next Friday, 10th August at 11AM how many people can be expected at the mataf area. These stats can then be used to avoid stampedes.

Future enhancements

  • Suggest smart routes to travelers to avoid stampedes

Built With

Share this project: