Skip to main content

sudan-atlas

DOI

Official codes, names and boundaries for Sudan's 18 states, the Abyei PCA area and 189 localities, with a matcher that turns messy Arabic and English place names into official P-codes.

pip install sudan-atlas            # matcher and data
pip install "sudan-atlas[geo]"     # plus GeoDataFrames (geopandas)
from sudan_atlas import match, get_states, get_localities, get_feature

match("El Hasaheesa", state_hint="Al Gezira", level=2)
# {'pcode': 'SD15034', 'name_en': 'Al Hasahisa', 'name_ar': 'الحصاحيصا', 'level': 2,
#  'score': 0.9, 'method': 'fuzzy', 'alternatives': [...]}

get_states()              # 19 dicts: pcode, name_en, name_ar, level, parent_pcode, point
get_localities("SD15")    # the localities of one state
get_feature("SD15034", "medium")   # GeoJSON Feature dict; "detailed", "medium" or "light"

from sudan_atlas import geo        # needs the [geo] extra
geo.localities("SD02")             # GeoDataFrame, EPSG:4326

Matching

match(name, state_hint=None, level=None) tries an exact match on the official names, then a table of known spellings, then fuzzy matching. A state hint (a P-code or a state name in any spelling) limits the search to that state; level is 1 for states, 2 for localities.

It never guesses silently. When the best candidate scores below 0.82, or a second place scores almost as high, pcode is None, method is "ambiguous" or "none", and alternatives lists the best three candidates for a person to choose from. Matcher(threshold=..., margin=...) changes those settings.

The npm package (npm install sudan-atlas) returns identical results.

Citing

If you use sudan-atlas in a report, paper or product, please cite it:

Shennan, A. (2026). Sudan Atlas: official names, P-codes and boundaries for Sudan's states and localities. Zenodo. https://doi.org/10.5281/zenodo.24191931

Website, map and map-maker: https://atlas-sudan.vercel.app

Licences and sources

Each licence covers its own files:

Files Licence Credit
Code MIT
Boundaries CC BY 3.0 IGO "OCHA (COD-AB Sudan), via HDX; Sudan Atlas" (COD-AB version v03)
Places, spellings (variants.json), rules CC BY 4.0 "Sudan Atlas"; sources include GeoNames (CC BY 4.0) and Wikidata (CC0)
OpenStreetMap town spellings (variants_osm.json only) ODbL 1.0 "© OpenStreetMap contributors"

The OpenStreetMap spellings are kept in their own file, so the ODbL's share-alike applies to that file alone, not to the boundaries or the other data. Matching results are not under the ODbL. Boundaries do not imply any opinion on the legal status of any territory. Details: https://github.com/aminshennan/sudan-atlas/blob/main/LICENSE-DATA

Metadata

Release files for sudan-atlas 0.1.5

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

Source distribution (sdist)

Source distribution for sudan-atlas 0.1.5
File Size Uploaded Provenance Actions
sudan_atlas-0.1.5.tar.gz 793.6 kB With provenance Details for sudan_atlas-0.1.5.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for sudan-atlas 0.1.5
File Interpreter ABI Platform Actions
sudan_atlas-0.1.5-py3-none-any.whl Python 3 none any Details for sudan_atlas-0.1.5-py3-none-any.whl

Total release size: 1.6 MB

Release files / sudan_atlas-0.1.5.tar.gz

Download URL sudan_atlas-0.1.5.tar.gz
Size 793.6 kB
Tags Source
SHA-256 checksum
How to use checksums
3640131248ce35f3aa6b70a82079cb3673153ef84cbce83b5db0c0cddf2a6b33
BLAKE2b-256 checksum
How to use checksums
33fbb09155f4e30b7049aa705d067cfdcf18e7d5e3b8c62b73890bc3c7431bf7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 22, 2026.

Transparency log

Release files / sudan_atlas-0.1.5-py3-none-any.whl

Download URL sudan_atlas-0.1.5-py3-none-any.whl
Size 799.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
20fc0247760649c42cded9516722bca56d436e70286908e50b1a32fe12bd114f
BLAKE2b-256 checksum
How to use checksums
c13012a339c1d127ac1e0764336d67869befda4ca0988bcb27f446ac154c5281
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 22, 2026.

Transparency log

Security for sudan-atlas 0.1.5

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.

Full provenance

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for sudan_atlas-0.1.5.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 22, 2026.

Transparency log

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.

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