Skip to main content

sagemath-data-graphs

sagemath-data-graphs packages the graph database resources historically shipped as SageMath's graphs data package. It has no dependency on Sage and performs no network access or writes at import or run time.

The distribution contains:

  • graphs.db, an immutable SQLite database of unlabeled graphs;
  • brouwer_srg_database.json, the strongly regular graph parameter database;
  • isgci_sage.xml, the ISGCI graph-class database; and
  • smallgraphs.txt, the small-graph names used with the ISGCI data.

Installation

python -m pip install sagemath-data-graphs

The Python import name is sage_data_graphs.

API

Use the resource API when consuming the raw files:

from sage_data_graphs import open_resource, resource, resource_path

with open_resource("smallgraphs.txt", "r") as stream:
    first_line = stream.readline()

# `resource_path` also works when a loader needs a real filesystem path.
with resource_path("isgci_sage.xml") as path:
    print(path)

The SQLite helper always opens the bundled database read-only and closes the connection after the context exits:

from sage_data_graphs import graph_database_connection

with graph_database_connection() as connection:
    rows = connection.execute("SELECT count(*) FROM graph_data").fetchone()[0]

The Brouwer JSON data can be decoded with one call:

from sage_data_graphs import load_brouwer_database

records = load_brouwer_database()

Only known top-level resource names are accepted. The package never modifies its installed resources; applications that download updates should store them in a separate user-writable location.

Releases

Publishing a GitHub Release runs the repository's Release GitHub Actions workflow. The workflow builds and checks the wheel and source distribution, smoke-tests the wheel in a clean environment, attaches both files to the GitHub Release, and publishes them to PyPI through Trusted Publishing. The Release tag must be 20210214.1 or v20210214.1. Configure a PyPI Trusted Publisher for this repository, the release.yml workflow, and the pypi environment before publishing the first release. Do not publish a release until the data-license blocker below has been resolved.

Data provenance and licensing

The Python source and packaging files are provided under GPL-2.0-or-later. The bundled databases come from several upstream sources and retain their source-specific terms. Sage's existing COPYING.txt labels graphs as None (database), so the precise redistribution terms must be confirmed with the data owners before a public PyPI release. See DATA_LICENSES.md for the provenance currently recorded by Sage.

For the new PyPI project, configure a pending Trusted Publisher with project sagemath-data-graphs, GitHub owner sagemath, repository data-graphs, workflow filename release.yml, and environment pypi.

Metadata

Release files for sagemath-data-graphs 20210214.1

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

Source distribution (sdist)

Source distribution for sagemath-data-graphs 20210214.1
File Size Uploaded
sagemath_data_graphs-20210214.1.tar.gz 465.3 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for sagemath-data-graphs 20210214.1
File Interpreter ABI Platform
sagemath_data_graphs-20210214.1-py3-none-any.whl Python 3 none any Details

Total release size: 937.5 kB

Release files / sagemath_data_graphs-20210214.1.tar.gz

Download URL sagemath_data_graphs-20210214.1.tar.gz
Size 465.3 kB
Tags Source
SHA-256 checksum
How to use checksums
2d021f4df20c4b5026e9d3167e485c54739e34f37b824c190441eecdd0abb5dd
BLAKE2b-256 checksum
How to use checksums
827b2c18e019b90d9b0bdd84a83d6bd76450c5610761938308265518f17d17d8
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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 Oct 2, 2026.

Transparency log

Release files / sagemath_data_graphs-20210214.1-py3-none-any.whl

Download URL sagemath_data_graphs-20210214.1-py3-none-any.whl
Size 472.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
1026877e28e79f6523b2637fec17d8479e094cc9436155c59b9ea15661a6e566
BLAKE2b-256 checksum
How to use checksums
f83facaa9af3ecf66570b51c20dc442a65e27ae980adb9c37ebab0a7d2ef2d89
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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 Oct 2, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

20210214.1 This release

2 release files

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