CityView
CityJSON loader and renderer for three.js, react-three-fiber, and Jupyter Notebook / JupyterLab.
Supports CityJSON format and CityJSONSeq format.
Contents
Packages
| Package Name | Description |
|---|---|
| cityview (top-level package) | Python package |
| three-cityjson | JavaScript / TypeScript package |
Installation
pip install cityview
Usage
Basic usage
VirtualView
import cityview as cv
view = cv.VirtualView(theme="light")
with open("./packages/three-cityjson/public/sample/daiba_sta.city.jsonl", "r") as f:
data = f.read()
view.layers = [
cv.CityJSONLayer(data=data, format="cityjsonseq")
]
view.update()
view
MapView
import cityview as cv
view = cv.MapView(theme="dark")
with open("./packages/three-cityjson/public/sample/daiba_sta.city.jsonl", "r") as f:
data = f.read()
view.layers = [
cv.CityJSONLayer(data=data, format="cityjsonseq")
]
view.update()
view
Handling click events
import cityview as cv
view = cv.VirtualView(theme="light")
with open("./packages/three-cityjson/public/sample/daiba_sta.city.jsonl", "r") as f:
data = f.read()
def handler(change):
print(change["new"])
view.observe(handler, names="click")
view.layers = [
cv.CityJSONLayer(data=data, format="cityjsonseq")
]
view.update()
view
Roadmap
- Online viewer
License
MIT
Metadata
Release files for cityview 0.2.0
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 |
|---|---|---|---|---|
| cityview-0.2.0.tar.gz | 988.9 kB | Without provenance | Details for cityview-0.2.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| cityview-0.2.0-py3-none-any.whl | Python 3 | none | any | Details for cityview-0.2.0-py3-none-any.whl |
Total release size: 2.0 MB
Release files / cityview-0.2.0.tar.gz
| Download URL | cityview-0.2.0.tar.gz |
|---|---|
| Size | 988.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
abd30fe9bb521dda6af62e2326d45e7bf0a158ebe74b310c8c7936044ef024eb
|
|
BLAKE2b-256 checksum How to use checksums |
9b363f3c0d391e4391bd345b7d9ac9b8af925d97138268983b71a8a5658d4ab4
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.8.3 CPython/3.12.5 Darwin/22.6.0
|
Release files / cityview-0.2.0-py3-none-any.whl
| Download URL | cityview-0.2.0-py3-none-any.whl |
|---|---|
| Size | 992.3 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
a6d1541ed12760331a9c14438e012ad24ff25c829c6c7595cc80355b75659a4c
|
|
BLAKE2b-256 checksum How to use checksums |
a9000c0f971b244b6a29cdc13872d01073860a0e6d2b0f8b854c0dc870518079
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.8.3 CPython/3.12.5 Darwin/22.6.0
|
Security for cityview 0.2.0
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.