LAPIN
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 :
- Create the OSM graph
python -m lapin --generate-graph
- 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'
- Specify the use of valhalla in
lapin/__main__.pyline 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.
- Specify the use of OSRM in
lapin/__main__.pyline 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 .
Metadata
Release files for onstreet-parking-study-dev 1.2.11
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| onstreet_parking_study_dev-1.2.11.tar.gz | 218.9 kB | Without provenance | Details for onstreet_parking_study_dev-1.2.11.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| onstreet_parking_study_dev-1.2.11-py3-none-any.whl | Python 3 | none | any | Details for onstreet_parking_study_dev-1.2.11-py3-none-any.whl |
Total release size: 453.0 kB
Release files / onstreet_parking_study_dev-1.2.11.tar.gz
| Download URL | onstreet_parking_study_dev-1.2.11.tar.gz |
|---|---|
| Size | 218.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
c8ca8e3282e0ce44067bf4971a43ea87f0e9a7eb9b4f2cd0051eb1225169201e
|
|
BLAKE2b-256 checksum How to use checksums |
2f4a02e1485735cb5b5511d81150ebdc67cc0577c4c975171793cb0cfdf9809f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.12.3
|
Release files / onstreet_parking_study_dev-1.2.11-py3-none-any.whl
| Download URL | onstreet_parking_study_dev-1.2.11-py3-none-any.whl |
|---|---|
| Size | 234.1 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
26bc707f7ac7f26840651fb7ccdd89c8e16df5ec8d7054f0524962959009393a
|
|
BLAKE2b-256 checksum How to use checksums |
bd68afe1ded0b2c3259853fb1dd9d37a1d4ce4384d1e2a0ca948422cc033da64
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.12.3
|
Security for onstreet-parking-study-dev 1.2.11
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.