graphbuilder
A tiny utility to build an undirected adjacency-list graph from a list of edges.
If you don't provide n (the number of nodes), it's inferred automatically
from the highest node index found in edges.
Install
pip install graphbuilder
Usage
from graphbuilder import build_graph
edges = [[0, 1], [0, 2], [1, 2], [2, 3], [1, 3]]
# n is optional — inferred automatically
graph = build_graph(edges)
print(graph)
# [[1, 2], [0, 2, 3], [0, 1, 3], [2, 1]]
# or provide n explicitly (e.g. to include isolated nodes)
graph = build_graph(edges, n=6)
print(graph)
# [[1, 2], [0, 2, 3], [0, 1, 3], [2, 1], [], []]
License
MIT
Metadata
Release files for adjacency-list-graphbuilder 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| adjacency_list_graphbuilder-0.1.0.tar.gz | 1.6 kB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| adjacency_list_graphbuilder-0.1.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 4.7 kB
Release files / adjacency_list_graphbuilder-0.1.0.tar.gz
| Download URL | adjacency_list_graphbuilder-0.1.0.tar.gz |
|---|---|
| Size | 1.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
44c453b09b37393f029bf27221d0335b1242b6e0e44a425fb673d7c9e974e4b5
|
|
BLAKE2b-256 checksum How to use checksums |
d171ef3d451edb9071b2af156f8269c56597c7ad27ba1c06babd9bc34c7c324b
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.10.7 {"installer":{"name":"uv","version":"0.10.7","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":null,"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Release files / adjacency_list_graphbuilder-0.1.0-py3-none-any.whl
| Download URL | adjacency_list_graphbuilder-0.1.0-py3-none-any.whl |
|---|---|
| Size | 3.1 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
c2b949d3d45ec419a70740c0dda25322cc0d12d67ff4dc80aa99a90ac29f3ad2
|
|
BLAKE2b-256 checksum How to use checksums |
f2da58f1c9bcea941b6392110e5a63e0db3efc6f86e5b267d28b8990e67f7a55
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.10.7 {"installer":{"name":"uv","version":"0.10.7","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":null,"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Security for adjacency-list-graphbuilder 0.1.0
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.
No provenance found
None of the files in this release were uploaded with provenance metadata.
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.