Skip to main content

BRO

This package can access the REST API from the BRO. Currently, this package provides functionality to request CPTs from the BRO when you provide a region of interest. The format is based on the REST API of the BRO, which is described here for CPTs.

Current options include retrieval of the following objects:

  1. CPTs (format: bytes, dict)

The package also allows export of the retrieved data in GeoJSON format.

Note 1: The BRO is only available for the Netherlands, other locations are not supported.

Note 2: The API of the BRO is limited and requesting large amounts of data may result in instability.

Installation

pip install bro

Use

Example usage to retrieve CPTs from the BRO as dictionaries.

from datetime import datetime

import Envelope
import Point
import get_cpt_characteristics_and_return_cpt_objects

begin_date = datetime(2015, 1, 1).strftime("%Y-%m-%d")
end_date = datetime(2023, 3, 3).strftime("%Y-%m-%d")

# Define small square area that returns 5 valid cpts
lower_corner = Point(51.92269686635185, 4.469594207611851)
upper_corner = Point(51.923034432171065, 4.470094707426648)

area = Envelope(lower_corner, upper_corner)
cpts = get_cpt_characteristics_and_return_cpt_objects(begin_date, end_date, area, as_dict= True)

LICENSE

MIT License

Copyright (c) 2023 VIKTOR

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

Publish

  • update changelog with version number
  • update bro/__version__.py
  • tag with version number

Release files for bro 0.2.11

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for bro 0.2.11
File Size Uploaded
bro-0.2.11.tar.gz 10.8 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for bro 0.2.11
File Interpreter ABI Platform
bro-0.2.11-py3-none-any.whl Python 3 none any Details

Total release size: 20.4 kB

Release files / bro-0.2.11.tar.gz

Download URL bro-0.2.11.tar.gz
Size 10.8 kB
Tags Source
SHA-256 checksum
How to use checksums
33375a7cb3f868edf83c4f6666fb19bdc886595a879a6360f43a034492972c34
BLAKE2b-256 checksum
How to use checksums
9140be73a4107e98bab4db3c3e2a0e6404818a7add93a639367021b8f4dda5b2
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.0.0 CPython/3.12.3

Release files / bro-0.2.11-py3-none-any.whl

Download URL bro-0.2.11-py3-none-any.whl
Size 9.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
e0d10c5ee486dc8c5b04c184da792d38d675b49b6e2cc5cee8c9a7f88fcb9447
BLAKE2b-256 checksum
How to use checksums
aef2f79924987232c0a97a4ef393ee82c30ce27f85775f7e3f5ae764e62b5683
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.0.0 CPython/3.12.3
Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page