Skip to main content

An LPR data analysis package (dev version)!

Project description

LAPIN

CI - Test

What it is

A framework for the analysis of on street parking occupancy via Licence Plate Recognition (LPR) data.

Getting started

Requirements

Install Lapin python's requirments with conda :

conda env create --name <YOUR_ENV_NAME> -f environment.yml

Optional

You may need to have a docker installation available on your machine. See Valhalla mapmatching.

Configuration

Project configuration

Create a config file for your project . You can create a blank one by running :

python -m lapin -c

Mapmatching configuration

You have the choice between two mapmatching engine : OSRM and Valhalla. The main difference being that while using Valhalla you can do the matching directly on the Montreal Geobase. Doing so improve the accuracy of the positionning of the plate on the geobase. Thus improving the quality of the results.

Valhalla

To use valhalla, you'll need to compute the OSM network from the geobase file. Then create the valhalla graph with valhalla engine and the OSM network. The step are the following :

  1. Create the OSM graph
python -m lapin --generate-graph
  1. Generate Valhalla's graph
sudo docker run --rm --name valhalla_gis-ops -p 8002:8002 -v $PWD/data/network/valhalla:/custom_files -e tile ghcr.io/gis-ops/docker-valhalla/valhalla:latest'
  1. Specify the use of valhalla in lapin/__main__.py line 113-115.
    matcher_host='<PATH_TO_LAPIN>/lapin/data/network/valhalla/valhalla_tiles.tar',
    matcher_client='valhalla',
    matcher_kwargs={'service_limits':{"trace": {"max_shape": 26000}}}, # your desired config
OSRM

To use OSRM simply identify a valid OSRM instance.

  1. Specify the use of OSRM in lapin/__main__.py line 113-115.
    matcher_host=<ADRESS_TO_OSRM_INSTANCE>,
    matcher_client='osrm',
    matcher_kwargs={},

Note : the instance must be launched with a sufficiently large max-matching-size parameter (e.g. 100000)

Lauching an analysis

Then excecute the package with the following command :

python -m lapin --conf-file <PATH_TO_YOUR_CONF_FILE>

Installing the module

Clone the repo and install the lapin package.

cd <repo_dir>
pip install .

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

onstreet_parking_study_dev-1.2.10.tar.gz (218.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

onstreet_parking_study_dev-1.2.10-py3-none-any.whl (234.1 kB view details)

Uploaded Python 3

File details

Details for the file onstreet_parking_study_dev-1.2.10.tar.gz.

File metadata

File hashes

Hashes for onstreet_parking_study_dev-1.2.10.tar.gz
Algorithm Hash digest
SHA256 cfea9ee3ac1c8dc603c764227c88410be4e103ab2d3e6e38d54dbbc9c1c2e63b
MD5 de8839f3368b9526162316450a9962b9
BLAKE2b-256 2f9b3ae124dd4666ce55a9d74c2a9030da4d3b676d6e2dd54348af48cb81f5da

See more details on using hashes here.

File details

Details for the file onstreet_parking_study_dev-1.2.10-py3-none-any.whl.

File metadata

File hashes

Hashes for onstreet_parking_study_dev-1.2.10-py3-none-any.whl
Algorithm Hash digest
SHA256 549c5929c0c238152c7eb92898571c693600fc37f65e78e577fedbc352f622f1
MD5 4cdc0193f8ca2894bdd185d02915dbfa
BLAKE2b-256 c4b8b69f80c3cbcd9fc1a2ebdb75cd1fb6560a42715832407cebd338f5f3ffd8

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page