Skip to main content

A compact Python library for modeling, analyzing, and visualizing optical network topologies.

Project description

Topolib 🚀

Topolib 🚀

Python Version License Issues Develop coverage Release coverage Documentation Status

Topolib is a compact, modular Python library for modeling, analyzing, and visualizing optical network topologies.
Goal: Provide researchers and engineers with a simple, extensible toolkit for working with nodes, links, metrics, and map-based visualizations.

🌐 Model | 📊 Analyze | 🗺️ Visualize | 🧩 Extend


📂 Examples

Explore ready-to-run usage examples in the examples/ folder!


🧭 Overview

Topolib is organized into four main modules:

  • 🧱 Elements: Node, Link — basic building blocks
  • 🕸️ Topology: Topology, Path — manage nodes, links, paths, and adjacency
  • 📈 Analysis: Metrics — compute node degree, link stats, connection matrices
  • 🖼️ Visualization: MapView — plot topologies on real maps

✨ Features

  • Modular, extensible design
  • Easy-to-use classes for nodes, links, and paths
  • Built-in metrics and analysis helpers
  • JSON import/export and interoperability
  • Ready for Sphinx, Read the Docs, and PyPI

⚡ Quickstart

python -m venv .venv
source .venv/bin/activate
pip install -U pip
pip install topolib

📚 Documentation

Full documentation: https://topolib.readthedocs.io/


📝 Basic usage

from topolib.elements.node import Node
from topolib.topology.topology import Topology

n1 = Node(1, 'A', 10.0, 20.0)
n2 = Node(2, 'B', 11.0, 21.0)
topo = Topology(nodes=[n1, n2])
# Add links, compute metrics, visualize, etc.

🛠️ Development

See CONTRIBUTING.md for development guidelines, commit message rules, and pre-commit setup.


📄 License

MIT — see LICENSE for details.

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

topolib-0.4.2.tar.gz (16.9 kB view details)

Uploaded Source

Built Distribution

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

topolib-0.4.2-py3-none-any.whl (19.6 kB view details)

Uploaded Python 3

File details

Details for the file topolib-0.4.2.tar.gz.

File metadata

  • Download URL: topolib-0.4.2.tar.gz
  • Upload date:
  • Size: 16.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.2.1 CPython/3.11.14 Linux/5.15.154+

File hashes

Hashes for topolib-0.4.2.tar.gz
Algorithm Hash digest
SHA256 78fc7fdbb24e1d14e1d3d1e6e1e5632050e48c62206b2dcbcab6ca3c4c67eac2
MD5 f181ef5ff4d328949e909452e6ae3fb0
BLAKE2b-256 8ad454cde4057c0f491f080970eb6168e1a9d363dd74107e384e27f27b129044

See more details on using hashes here.

File details

Details for the file topolib-0.4.2-py3-none-any.whl.

File metadata

  • Download URL: topolib-0.4.2-py3-none-any.whl
  • Upload date:
  • Size: 19.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.2.1 CPython/3.11.14 Linux/5.15.154+

File hashes

Hashes for topolib-0.4.2-py3-none-any.whl
Algorithm Hash digest
SHA256 d950f40f2c3f04c67389260ec1661482f59410076b04bee3a163f92d3d5bc5b4
MD5 f5e58376d73617fae0928ec5ff08af48
BLAKE2b-256 143f285451ea4663aa697cecad270ae08ccea211d77c2a4e5d04497218dc969c

See more details on using hashes here.

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