Chinese Province, City and Area Recognition Utilities (Updated 2025)
Project description
A Python module for extracting Chinese province, city, and district information from address strings.
Fork from DQinYuan/chinese_province_city_area_mapper with updated 2025 administrative division data.
Installation
pip install cpca-linch
Usage
import cpca
df = cpca.transform(["徐汇区虹漕路461号58号楼5楼", "广东省中山市沙溪镇云汉轻纺城"])
print(df)
Output:
省 市 区 地址 0 上海市 上海市 徐汇区 虹漕路461号58号楼5楼 1 广东省 中山市 沙溪镇 云汉轻纺城
Key Improvements
Updated administrative division data to 2025 (from xiangyuecn/AreaCity-JsSpider-StatsGov)
Support for towns in prefecture-level cities without districts (Dongguan, Zhongshan, Danzhou, Jiayuguan)
Removed latitude/longitude data for smaller package size
Full documentation: https://github.com/laofahai/cpca-linch
License
MIT
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file cpca_linch-0.4.5.tar.gz.
File metadata
- Download URL: cpca_linch-0.4.5.tar.gz
- Upload date:
- Size: 37.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
087bc1e00fd72b30af4b7a0afc41afe1f8dea79b311e450906e83b0922e2d22f
|
|
| MD5 |
b517f0e8d0ca5b6513a344d8b073e79a
|
|
| BLAKE2b-256 |
873e71121bb1974f138de6d873753a98d502e6dcd1332d6ee2b19867190918e9
|
File details
Details for the file cpca_linch-0.4.5-py3-none-any.whl.
File metadata
- Download URL: cpca_linch-0.4.5-py3-none-any.whl
- Upload date:
- Size: 32.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ac4d312c2eeb007075d22beac6f9c0ed3052a7fc69b2d36ebe7184a77540910e
|
|
| MD5 |
50cbad8cf9e2b9bcbee4ed842bc6a2d8
|
|
| BLAKE2b-256 |
db163e0287e2292b0716784b02079658db4477ad5a1810880f667c56ef7bdfd0
|