A Python package for graph algorithms including Dijkstra's shortest path
Project description
graphs_carmen
This is a Python package for graph algorithms, including Dijkstra's shortest path. It is structured for easy installation and command-line usage.
Installation
To install locally:
pip install .
Usage
Run the shortest path algorithm from the command line:
python test.py graph.txt
Graph File Format
The input file should start with the number of vertices, followed by edges in the format:
source destination weight
Example:
9
0 1 4
0 7 8
1 2 8
1 7 11
2 3 7
2 8 2
3 4 9
3 5 14
4 5 10
5 6 2
6 7 1
6 8 6
7 8 7
Output
The script prints shortest distances from the source node (0), and the shortest path to each node.
Repository
GitHub URL: https://github.com/csirhall/dijkstra-sp
Branches
mainbranch is protecteddevbranch is used for development
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file graphs_csirhall-0.0.3.tar.gz.
File metadata
- Download URL: graphs_csirhall-0.0.3.tar.gz
- Upload date:
- Size: 9.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c337a4914ffd49e8fce46987ced1c103229254c9a92baa2a61c22a22cc35e2f3
|
|
| MD5 |
246fa362c675ffe70dc95ac6ccf98e7c
|
|
| BLAKE2b-256 |
e138d3d4d448b6e2b6aa9264864231f8df369f24ba887dcaa06d3c3a8e639284
|
File details
Details for the file graphs_csirhall-0.0.3-py3-none-any.whl.
File metadata
- Download URL: graphs_csirhall-0.0.3-py3-none-any.whl
- Upload date:
- Size: 9.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6de515ce408ae4a62e6fbe622ba3ac6a706df393e662ae624c3395215b03775b
|
|
| MD5 |
8c607639afab6142199bd4aca31dfe90
|
|
| BLAKE2b-256 |
a9fa5a5718751726fef0e556df7187b934aba3619c2d89e6200800d5b12eaa2e
|