pycitysim

pycitysim

City Simulator and OpenCity databases Python SDK

安装 Installation

pip install pycitysim

安装 grpcio 的过程中,如果出现: When installing grpcio, you may encounter the following error:

pip install fails with "No such file or directory: 'c++': 'c++'"

代表缺少 C++相关依赖。在 Debian 镜像上,执行: It means that C++ related dependencies are missing. On the Debian image, execute:

sudo apt install build-essential

在 alpine 镜像上,执行: On the alpine image, execute:

apk add g++

主要子库 Sub-packages

  • pycitysim.apphub: OpenCity后端交互库。OpenCity backend interaction package.
  • pycitysim.map: 地图数据操作库。Map data operation package.
  • pycitysim.routing: 路径规划操作库。Routing operation package.
  • pycitysim.sim: 模拟器gRPC接入客户端。City Simulator gRPC access client.
  • pycitysim.urbankg: 城市知识图谱访问模块。City knowledge graph access module.

示例代码

访问 examples 查看示例代码。

 1r"""
 2# pycitysim
 3
 4City Simulator and OpenCity databases Python SDK
 5
 6## 安装 Installation
 7
 8```shell
 9pip install pycitysim
10```
11
12安装 grpcio 的过程中,如果出现:
13When installing grpcio, you may encounter the following error:
14
15```
16pip install fails with "No such file or directory: 'c++': 'c++'"
17```
18
19代表缺少 C++相关依赖。在 Debian 镜像上,执行:
20It means that C++ related dependencies are missing. On the Debian image, execute:
21
22```shell
23sudo apt install build-essential
24```
25
26在 alpine 镜像上,执行:
27On the alpine image, execute:
28
29```shell
30apk add g++
31```
32
33## 主要子库 Sub-packages
34
35- pycitysim.apphub: OpenCity后端交互库。OpenCity backend interaction package.
36- pycitysim.map: 地图数据操作库。Map data operation package.
37- pycitysim.routing: 路径规划操作库。Routing operation package.
38- pycitysim.sim: 模拟器gRPC接入客户端。City Simulator gRPC access client.
39- pycitysim.urbankg: 城市知识图谱访问模块。City knowledge graph access module.
40
41## 示例代码
42
43访问 [examples](https://github.com/tsinghua-fib-lab/pycitysim/-/tree/main/examples?ref_type=heads) 查看示例代码。
44
45"""
46
47from . import map, routing, sidecar, sim, urbankg, utils, apphub
48
49__all__ = [
50    "map",
51    "routing",
52    "sidecar",
53    "sim",
54    "urbankg",
55    "utils",
56    "apphub",
57]