The final project of the course Python 19 Data Science, on the Web framework - Django.
With this application, you will be able to automatically identify car registration numbers in images, track the length of parking for each unique car, and calculate accumulated parking costs. Parking is not just a place for your car, it is an important part of the city infrastructure that affects the comfort and safety of all road users. Every time you choose a parking place, think about how your decision will affect others. Leave enough space for pedestrians, cyclists and other drivers. Proper parking is respect for others and a contribution to creating a safer and more convenient city.
Web_World: Park-Auto - it performs the following algorithm model:
- paddleocr - aims to create multilingual, awesome, leading, and practical OCR tools that help users train better models and apply them into practice.
- opencv - open Source Computer Vision Library
Web_World: Park-Auto - performs the following features:
- 👨💻 Authorization and Authentication: - users can register, log in, and log out.
- 🚗 Image Uploading: - users can upload images for car number recognition via personal profile.
- 🤓 User profile management: - car auto history, recognized numbers, payment history.
- 😎 Admin profile management - adjusted django admin profile, giving full project management possibility.
- 📆 Celery task scheduler - task scheduler that performs auto email notifications, for blacklisted users.
- 🌌 Model algorithm: paddleocr - recognition algorithm already trained and implemented.
- 🐳 Docker container: - the project can start-up via containerized Docker.
- The first thing to do is to clone the repository:
git clone -b main https://github.com/IVadymMarchenko/web_world.git- Activate virtual environment and install dependencies from the root folder where pyproject.toml exists:
poetry shellpoetry install --no-root-
Once
poetryhas finished downloading the dependencies:- Create .env file in project root and fill in the file like this example:
DJANGO_SECRET_KEY=*your secret key*
POSTGRES_DB_NAME=*your postgre db name*
POSTGRES_USER=postgres
POSTGRES_PASSWORD=w*your postgre db password*
POSTGRES_PORT=5432
POSTGRES_DOMAIN=*your postgre domain*
EMAIL_HOST=*your main smtp*
EMAIL_PORT=*your main smtp port*
EMAIL_HOST_USER=*your email address*
EMAIL_HOST_PASSWORD=*your email password*
CLOUD_NAME=*your cloudidnary name*
API_KEY=*your cloudinary api key*
API_SECRET=*your api secret phrase*
REDIS_HOST0=*your redis host for celery*/0
REDIS_HOST1=*your redis host for celery*/1- Then run docker container and make migrations for db:
- Run postgre docker container.
- Run redis docker container.
- From any terminal window:
For postgre:
docker run --name postg_data_science -d -h localhost -p 5432:5432 -u postgres -e POSTGRES_PASSWORD=*your password from env file POSTGRES_PASSWORD* postgresFor redis:
docker run --name my-redis -d -p 6379:6379 redisFrom root projectfolder /app_parking/ make migrations:
(env)$> cd app_parking
(env)$app_parking> python manage.py makemigrations
(env)$app_parking> python manage.py migrate- Before server start-up run celery worker and beat commands in separate terminals:
- Run celery worker commdand.
- Run celery beat command.
- Run web server.
- From project folder /app_parking/:
(env)$> cd app_parkingFirst terminal window - for celery worker commdand:
(env)$app_parking> celery -A app_parking worker -l info -P eventletSecond terminal window - for celery beat commdand:
(env)$app_parking> celery -A app_parking beat -l infoThird terminal window - for web server start-up:
(env)$app_parking> py manage.py runserver - And navigate to `http://127.0.0.1:8000/.
From the root folder:
-
Build containers via
docker-compose:docker-compose build
-
Start containers:
docker-compose up
-
Open
http://localhost:8000in a browser.
Project is mainly based on:
- 🐍 Python - backend programming language.
- 🌠 HTML/CSS/JavaScript: - frontend programming languages.
- 🤠 Django - python web framework.
- 🌌 Paddleocr / OpenCV - vision image recognition models.
- 🐘 PostgreSQL - object-relational database management system.
- ⚙️ Redis - data base that is responsible for the storage and cache of the main database.
- 📆 Celery - automation task scheduler.
- 🐳 Docker - a software platform for rapid application development, testing and deployment.
- 👀 GitHub - storing, tracking, and collaborating on project development/deployment.
- 🎰 Googleapis - a service by Google that provides a diverse collection of web fonts.
- 🌎 Koyeb - service for project deplotment.
- 👨👦👦 Trello - a visual tool that allows your team to manage projects, workflows and any type of job.




