Skip to main content

Graph traversal & pathfinding (informed and uninformed search) with a Rust core

Project description

graphfinder (Python)

Graph traversal & pathfinding (informed and uninformed search) with a Rust core.

import graphfinder as gf

# A* on a maze
r = gf.search(gf.sample_maze("wall"), algorithm="astar", heuristic="manhattan")
print(r)                     # SearchResult(found=True, cost=20, expanded=25, ...)
print(r.cost, r.nodes_expanded, len(r.trace))

# Explicit weighted graph from a generator
edges = gf.gen_barabasi_albert(200, 3, seed=1)
r = gf.search_graph(200, edges, start=0, goal=199, algorithm="bidirectional")

# Implicit graph (lazy successors; states are ints or tuples of ints)
def successors(s):
    return [(s + 1, 1.0), (s * 2, 1.0)] if s < 1000 else []
r = gf.search(successors, start=1, goal=27, algorithm="bfs")

Build from source (Rust core via maturin):

pip install maturin
maturin develop --release
python examples/quickstart.py

See the top-level README and ROADMAP.md for the full feature list. A visualization layer (graphfinder.viz) is planned for Phase 4.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

graphfinder-0.5.0.tar.gz (39.9 kB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

graphfinder-0.5.0-cp39-abi3-win_amd64.whl (291.0 kB view details)

Uploaded CPython 3.9+Windows x86-64

graphfinder-0.5.0-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (438.6 kB view details)

Uploaded CPython 3.9+manylinux: glibc 2.17+ x86-64

graphfinder-0.5.0-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl (417.3 kB view details)

Uploaded CPython 3.9+manylinux: glibc 2.17+ ARM64

graphfinder-0.5.0-cp39-abi3-macosx_11_0_arm64.whl (377.2 kB view details)

Uploaded CPython 3.9+macOS 11.0+ ARM64

graphfinder-0.5.0-cp39-abi3-macosx_10_12_x86_64.whl (394.7 kB view details)

Uploaded CPython 3.9+macOS 10.12+ x86-64

File details

Details for the file graphfinder-0.5.0.tar.gz.

File metadata

  • Download URL: graphfinder-0.5.0.tar.gz
  • Upload date:
  • Size: 39.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for graphfinder-0.5.0.tar.gz
Algorithm Hash digest
SHA256 a1a794c6f163a5db65d3b23a0d14f64c52c28d9714bc32619b094230f8fe6487
MD5 1a53046c79385654f63e4f23968b2cb5
BLAKE2b-256 e2e72bc3d085219e9e8067526aa9c191ec66753cec064561cf7f26bfb541eee1

See more details on using hashes here.

Provenance

The following attestation bundles were made for graphfinder-0.5.0.tar.gz:

Publisher: release-pypi.yml on graphfinder/graphfinder.github.io

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file graphfinder-0.5.0-cp39-abi3-win_amd64.whl.

File metadata

  • Download URL: graphfinder-0.5.0-cp39-abi3-win_amd64.whl
  • Upload date:
  • Size: 291.0 kB
  • Tags: CPython 3.9+, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for graphfinder-0.5.0-cp39-abi3-win_amd64.whl
Algorithm Hash digest
SHA256 6a2e86416a86d41d4fc01c7e63e31669828a025ad5b7a428c37f3c858da745b1
MD5 53e20ac9418df92ab886eba4d558ed5c
BLAKE2b-256 a9ca3365703a87c82c798d926df167bd8a5883d494a5b8fe7c7d54f91ea49357

See more details on using hashes here.

Provenance

The following attestation bundles were made for graphfinder-0.5.0-cp39-abi3-win_amd64.whl:

Publisher: release-pypi.yml on graphfinder/graphfinder.github.io

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file graphfinder-0.5.0-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for graphfinder-0.5.0-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 e320e52292a72176fd1db5b027d2c62df68c472f8ad94becb73d35f67ddff561
MD5 861ae16c56d430553967ab6ddf01c926
BLAKE2b-256 da89b610415fc6fceb6c1ab4ac2e73b4363da5c76d03c7d6e385eb0112458823

See more details on using hashes here.

Provenance

The following attestation bundles were made for graphfinder-0.5.0-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl:

Publisher: release-pypi.yml on graphfinder/graphfinder.github.io

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file graphfinder-0.5.0-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl.

File metadata

File hashes

Hashes for graphfinder-0.5.0-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 43fcb8adb8cfdc1a71a275313cd3b127776790639228faaef4ac35fabd330076
MD5 9d7b7b3ab4770de243ed847472bfd2d1
BLAKE2b-256 9274ae2d75a1d9fd67518d0cea5dbce6bfd8e893172edb9fb8780d3b12674a4a

See more details on using hashes here.

Provenance

The following attestation bundles were made for graphfinder-0.5.0-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl:

Publisher: release-pypi.yml on graphfinder/graphfinder.github.io

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file graphfinder-0.5.0-cp39-abi3-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for graphfinder-0.5.0-cp39-abi3-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 8dacd4d56f8838f107b62aaaca15739f3e2a16a14fa50d1a8284dd521d032406
MD5 d793758c8e82c4253ae51272f175b54e
BLAKE2b-256 eb01b006f11fa79c9cfcaa6dafb4306e54fb26224fc74f4cc7876c7be9e689ee

See more details on using hashes here.

Provenance

The following attestation bundles were made for graphfinder-0.5.0-cp39-abi3-macosx_11_0_arm64.whl:

Publisher: release-pypi.yml on graphfinder/graphfinder.github.io

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file graphfinder-0.5.0-cp39-abi3-macosx_10_12_x86_64.whl.

File metadata

File hashes

Hashes for graphfinder-0.5.0-cp39-abi3-macosx_10_12_x86_64.whl
Algorithm Hash digest
SHA256 7c26866907f7c338ed004eda3ddbcdcff633d004e2a3685a044484585e8094b6
MD5 65c91a83ed48e5a3c149f6a6ffda90cb
BLAKE2b-256 8d4c62d55b458f7316a498e59a25de0c904eedccc617b46612084407279528c5

See more details on using hashes here.

Provenance

The following attestation bundles were made for graphfinder-0.5.0-cp39-abi3-macosx_10_12_x86_64.whl:

Publisher: release-pypi.yml on graphfinder/graphfinder.github.io

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page