Skip to main content

No project description provided

Project description

ugraph

PyPI version Downloads black isort License: MIT mypyc flake8 pylint

Extend your graphs beyond structure—add meaning with ugraph.

ugraph builds on igraph to provide a powerful way to define and work with custom node and link types in your graphs. This package is ideal for those who need more than just graph structure—it empowers you to combine graph data with rich information via Python dataclasses, and comes with built-in support for JSON storage and 3D visualizations.

Because your graphs aren't just for you
(igraph → ugraph)


Why ugraph?

Graphs often represent more than their edges and nodes—they carry data, behaviors, and relationships that need to be understood in context. ugraph bridges this gap by enabling:

  • Custom node and link classes: Add type-safe attributes and behaviors to your graph elements.
  • Data serialization: Easily save and load your graphs in JSON format for persistence and sharing.
  • 3D visualization: Render interactive, browser-based 3D visualizations in HTML using Plotly.

With ugraph, your graphs are as understandable and maintainable as the data they represent.


Features at a Glance

  • Custom Classes: Define your nodes and links as Python dataclasses, allowing for type hints, IDE autocompletion, and type checking.
  • Serialization: Store and reload your networks seamlessly using JSON files.
  • Interactive Visualization: Generate 3D plots of your graphs in HTML for better insights and presentation.

Disclaimer

ugraph is not intended for creating graph figures or visualizations (e.g., bar charts, scatter plots). It is a tool for working with graph data structures (nodes and links) and enhancing their usability.


Installation

Install ugraph using pip:

pip install ugraph

(if you need igraph's cairo-based plotting, use pip install ugraph[cairo])


Quick Start

ugraph works similarly to igraph, with the added flexibility of custom node and link types. You can define attributes like coordinates, IDs, or any other domain-specific data in a type-safe and Pythonic way.

Explore usage examples in the examples directory, or start with a minimal example.

Documentation

For an extended introduction and code snippets, see docs/getting_started.md.


Credits

This project builds upon the excellent igraph library. We acknowledge and thank the igraph community for their foundational work.


License

See the LICENSE file for rights and limitations (MIT).

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

ugraph-0.80.dev1.tar.gz (15.1 kB view details)

Uploaded Source

Built Distribution

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

ugraph-0.80.dev1-py3-none-any.whl (17.7 kB view details)

Uploaded Python 3

File details

Details for the file ugraph-0.80.dev1.tar.gz.

File metadata

  • Download URL: ugraph-0.80.dev1.tar.gz
  • Upload date:
  • Size: 15.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.1.1 CPython/3.10.4 Windows/10

File hashes

Hashes for ugraph-0.80.dev1.tar.gz
Algorithm Hash digest
SHA256 d72fd7310d5b6b74cbc522746dd890a9d0a374500b0a5140d4a0bfa789303dfc
MD5 cecca8548d5a077f0facd7561c16ee93
BLAKE2b-256 ee15aca458cd1e82bb4e40722f755c71b1110d243e0c12faf478c7188c02fee3

See more details on using hashes here.

File details

Details for the file ugraph-0.80.dev1-py3-none-any.whl.

File metadata

  • Download URL: ugraph-0.80.dev1-py3-none-any.whl
  • Upload date:
  • Size: 17.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.1.1 CPython/3.10.4 Windows/10

File hashes

Hashes for ugraph-0.80.dev1-py3-none-any.whl
Algorithm Hash digest
SHA256 552edf64c5e23bd4faa519680d7daac3d4297ca70f7d86dff3e82e881139d442
MD5 e0de65fadff49d4d6f13086dea152b71
BLAKE2b-256 2b2425b12b0f25e9fb952cf12618561ca6494c7da1f6090cd6fa1d82b6e7dbd5

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