Skip to main content

sage-data-elliptic-curves

sage-data-elliptic-curves packages two small, read-only elliptic-curve databases historically distributed as SageMath's elliptic_curves package:

  • John Cremona's elliptic curves of conductor below 10,000, represented as a compact SQLite database; and
  • William Stein's collection of interesting elliptic curves, combined with the Cremona records and grouped into text files by rank.

The package has no dependency on SageMath. It exposes the data through importlib.resources, so consumers do not need to know where the wheel was installed.

Install

python -m pip install sage-data-elliptic-curves

Use

from sage_data_elliptic_curves import (
    available_ranks,
    cremona_mini_connection,
    iter_rank,
)

print(available_ranks())

record = next(iter_rank(3))
print(record.label, record.ainvs)

with cremona_mini_connection() as connection:
    row = connection.execute(
        "SELECT curve, eqn FROM t_curve WHERE curve = ?", ("11a1",)
    ).fetchone()
    print(row)

cremona_mini_resource() and rank_resource(rank) return standard importlib.resources traversables. For APIs that require filesystem paths, use the cremona_mini_path() and rank_path(rank) context managers; their paths are valid only while the corresponding context is active.

Regenerate the packaged data

The unmodified legacy inputs are retained under sources/. Regenerate all derived resources with:

python generate.py

Check that the committed resources are logically identical to a fresh generation without modifying them:

python generate.py --check

The SQLite comparison is logical rather than byte-for-byte because SQLite file layout can vary across SQLite releases.

Develop

python -m pip install -e '.[test]'
python generate.py --check
python -m pytest
python -m build

After the data terms are confirmed, publishing is performed only by the Release GitHub Actions workflow when a GitHub Release is published. The workflow checks the generated databases, builds and validates both distributions, smoke-tests the wheel in a clean environment, attaches the artifacts to that Release, and uses PyPI Trusted Publishing through the protected pypi environment. The Release tag must be 0.8.1 or v0.8.1. Configure the repository, release.yml workflow, and pypi environment as a PyPI Trusted Publisher before publishing the first Release.

Metadata

Release files for sage-data-elliptic-curves 0.8.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 sage-data-elliptic-curves 0.8.1
File Size Uploaded
sage_data_elliptic_curves-0.8.1.tar.gz 5.0 MB Details

Built distribution (wheel)

Table of built distributions (wheels) for sage-data-elliptic-curves 0.8.1
File Interpreter ABI Platform
sage_data_elliptic_curves-0.8.1-py3-none-any.whl Python 3 none any Details

Total release size: 9.3 MB

Release files / sage_data_elliptic_curves-0.8.1.tar.gz

Download URL sage_data_elliptic_curves-0.8.1.tar.gz
Size 5.0 MB
Tags Source
SHA-256 checksum
How to use checksums
b31297c7357b8757092d734d74cfde5c3dc419dc9b14d751a1df5ae447b4d6eb
BLAKE2b-256 checksum
How to use checksums
5d97a3e9b194e6130b6af842306f0bd762c99f2acd8fe38e95d2b47ba66807b7
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 Aug 24, 2026.

Transparency log

Release files / sage_data_elliptic_curves-0.8.1-py3-none-any.whl

Download URL sage_data_elliptic_curves-0.8.1-py3-none-any.whl
Size 4.3 MB
Tags Python 3
SHA-256 checksum
How to use checksums
fbca3906bacd55ef980a80cdf778199f9e43ccee1f8fbde5a57039b04ecd2eff
BLAKE2b-256 checksum
How to use checksums
2669d9819200f8ba5693706801f42c5fb315910549ad49944b032358d4168e1c
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 Aug 24, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

0.8.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