dagua 0.0.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- dagua-0.0.0/LICENSE +21 -0
- dagua-0.0.0/PKG-INFO +58 -0
- dagua-0.0.0/README.md +17 -0
- dagua-0.0.0/dagua/__init__.py +9 -0
- dagua-0.0.0/dagua/defaults.py +9 -0
- dagua-0.0.0/dagua/elements.py +5 -0
- dagua-0.0.0/dagua/graph.py +6 -0
- dagua-0.0.0/dagua/io.py +8 -0
- dagua-0.0.0/dagua/layout/__init__.py +4 -0
- dagua-0.0.0/dagua/layout/constraints.py +14 -0
- dagua-0.0.0/dagua/layout/engine.py +8 -0
- dagua-0.0.0/dagua/layout/projection.py +5 -0
- dagua-0.0.0/dagua/layout/schedule.py +6 -0
- dagua-0.0.0/dagua/render/__init__.py +6 -0
- dagua-0.0.0/dagua/render/graphviz.py +5 -0
- dagua-0.0.0/dagua/render/mpl.py +5 -0
- dagua-0.0.0/dagua/render/svg.py +5 -0
- dagua-0.0.0/dagua/routing.py +5 -0
- dagua-0.0.0/dagua/style.py +5 -0
- dagua-0.0.0/dagua/utils.py +4 -0
- dagua-0.0.0/dagua.egg-info/PKG-INFO +58 -0
- dagua-0.0.0/dagua.egg-info/SOURCES.txt +30 -0
- dagua-0.0.0/dagua.egg-info/dependency_links.txt +1 -0
- dagua-0.0.0/dagua.egg-info/requires.txt +20 -0
- dagua-0.0.0/dagua.egg-info/top_level.txt +1 -0
- dagua-0.0.0/pyproject.toml +107 -0
- dagua-0.0.0/setup.cfg +4 -0
- dagua-0.0.0/tests/test_elements.py +1 -0
- dagua-0.0.0/tests/test_graph.py +1 -0
- dagua-0.0.0/tests/test_io.py +1 -0
- dagua-0.0.0/tests/test_routing.py +1 -0
- dagua-0.0.0/tests/test_style.py +1 -0
dagua-0.0.0/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 John Mark Taylor
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
dagua-0.0.0/PKG-INFO
ADDED
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: dagua
|
|
3
|
+
Version: 0.0.0
|
|
4
|
+
Summary: GPU-accelerated differentiable graph layout engine built on PyTorch
|
|
5
|
+
Author: John Mark Taylor
|
|
6
|
+
License-Expression: MIT
|
|
7
|
+
Project-URL: Homepage, https://github.com/johnmarktaylor91/dagua
|
|
8
|
+
Project-URL: Repository, https://github.com/johnmarktaylor91/dagua
|
|
9
|
+
Project-URL: Issues, https://github.com/johnmarktaylor91/dagua/issues
|
|
10
|
+
Keywords: graph,layout,visualization,pytorch,dag,graphviz,hierarchical
|
|
11
|
+
Classifier: Development Status :: 2 - Pre-Alpha
|
|
12
|
+
Classifier: Intended Audience :: Developers
|
|
13
|
+
Classifier: Intended Audience :: Science/Research
|
|
14
|
+
Classifier: Programming Language :: Python :: 3
|
|
15
|
+
Classifier: Programming Language :: Python :: 3.9
|
|
16
|
+
Classifier: Programming Language :: Python :: 3.10
|
|
17
|
+
Classifier: Programming Language :: Python :: 3.11
|
|
18
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
19
|
+
Classifier: Topic :: Scientific/Engineering :: Visualization
|
|
20
|
+
Classifier: Topic :: Software Development :: Libraries :: Python Modules
|
|
21
|
+
Requires-Python: >=3.9
|
|
22
|
+
Description-Content-Type: text/markdown
|
|
23
|
+
License-File: LICENSE
|
|
24
|
+
Requires-Dist: torch>=1.9
|
|
25
|
+
Provides-Extra: render
|
|
26
|
+
Requires-Dist: matplotlib>=3.5; extra == "render"
|
|
27
|
+
Provides-Extra: graphviz
|
|
28
|
+
Requires-Dist: graphviz>=0.20; extra == "graphviz"
|
|
29
|
+
Provides-Extra: dev
|
|
30
|
+
Requires-Dist: matplotlib>=3.5; extra == "dev"
|
|
31
|
+
Requires-Dist: pytest>=7.0; extra == "dev"
|
|
32
|
+
Requires-Dist: pytest-cov; extra == "dev"
|
|
33
|
+
Requires-Dist: ruff>=0.4; extra == "dev"
|
|
34
|
+
Requires-Dist: mypy; extra == "dev"
|
|
35
|
+
Requires-Dist: pip-audit; extra == "dev"
|
|
36
|
+
Requires-Dist: pre-commit; extra == "dev"
|
|
37
|
+
Provides-Extra: test
|
|
38
|
+
Requires-Dist: pytest>=7.0; extra == "test"
|
|
39
|
+
Requires-Dist: matplotlib>=3.5; extra == "test"
|
|
40
|
+
Dynamic: license-file
|
|
41
|
+
|
|
42
|
+
# dagua
|
|
43
|
+
|
|
44
|
+
GPU-accelerated differentiable graph layout engine built on PyTorch.
|
|
45
|
+
|
|
46
|
+
**DAG + agua.** Directed acyclic graphs + water. Named after the Dagua River in Colombia — a river flows downhill (like a DAG), never cycles back (acyclic), and finds its own path through the landscape (like gradient descent finding optimal node positions).
|
|
47
|
+
|
|
48
|
+
## Why?
|
|
49
|
+
|
|
50
|
+
Graphviz has dominated graph visualization for 30 years but has hard scaling limits. No existing Python package provides pip-installable, hierarchical (Sugiyama-style) graph layout. Dagua fills this gap: `pip install dagua`, pure Python + PyTorch, GPU-accelerated, hierarchical layout with composable constraints.
|
|
51
|
+
|
|
52
|
+
## Status
|
|
53
|
+
|
|
54
|
+
Pre-alpha. Under active development.
|
|
55
|
+
|
|
56
|
+
## License
|
|
57
|
+
|
|
58
|
+
MIT
|
dagua-0.0.0/README.md
ADDED
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
# dagua
|
|
2
|
+
|
|
3
|
+
GPU-accelerated differentiable graph layout engine built on PyTorch.
|
|
4
|
+
|
|
5
|
+
**DAG + agua.** Directed acyclic graphs + water. Named after the Dagua River in Colombia — a river flows downhill (like a DAG), never cycles back (acyclic), and finds its own path through the landscape (like gradient descent finding optimal node positions).
|
|
6
|
+
|
|
7
|
+
## Why?
|
|
8
|
+
|
|
9
|
+
Graphviz has dominated graph visualization for 30 years but has hard scaling limits. No existing Python package provides pip-installable, hierarchical (Sugiyama-style) graph layout. Dagua fills this gap: `pip install dagua`, pure Python + PyTorch, GPU-accelerated, hierarchical layout with composable constraints.
|
|
10
|
+
|
|
11
|
+
## Status
|
|
12
|
+
|
|
13
|
+
Pre-alpha. Under active development.
|
|
14
|
+
|
|
15
|
+
## License
|
|
16
|
+
|
|
17
|
+
MIT
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
"""Dagua: GPU-accelerated differentiable graph layout engine built on PyTorch."""
|
|
2
|
+
|
|
3
|
+
__version__ = "0.0.0"
|
|
4
|
+
|
|
5
|
+
# Public API will be re-exported here once modules are implemented:
|
|
6
|
+
# from dagua.elements import Node, Edge, Cluster
|
|
7
|
+
# from dagua.graph import Graph
|
|
8
|
+
# from dagua.style import NodeStyle, EdgeStyle, ClusterStyle
|
|
9
|
+
# from dagua.defaults import set_default_device, set_default_theme
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
"""Module-level defaults — device, theme.
|
|
2
|
+
|
|
3
|
+
Minimal global state. Prefer passing these explicitly to Graph; these exist
|
|
4
|
+
only as convenience to avoid repeating device='cuda' on every call.
|
|
5
|
+
|
|
6
|
+
Usage:
|
|
7
|
+
dagua.set_default_device('cuda')
|
|
8
|
+
dagua.set_default_theme('dark')
|
|
9
|
+
"""
|
dagua-0.0.0/dagua/io.py
ADDED
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
"""Graph construction and export utilities.
|
|
2
|
+
|
|
3
|
+
from_edges, from_edge_index, from_networkx, from_dict — thin converters
|
|
4
|
+
that build Graph instances from various input formats.
|
|
5
|
+
to_dot — export to Graphviz DOT format.
|
|
6
|
+
|
|
7
|
+
Graph.from_* classmethods are thin wrappers over functions here.
|
|
8
|
+
"""
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
"""Composable constraint loss functions.
|
|
2
|
+
|
|
3
|
+
Each constraint is a callable: (pos, graph_data) -> scalar loss.
|
|
4
|
+
|
|
5
|
+
Built-in constraints:
|
|
6
|
+
- DAG: enforce top-to-bottom ordering for directed edges
|
|
7
|
+
- Repel: prevent node overlap via pairwise repulsion
|
|
8
|
+
- Attract: pull connected nodes together (edge attraction)
|
|
9
|
+
- Overlap: hard overlap penalty (complements projection.py)
|
|
10
|
+
- Cluster: group related nodes spatially
|
|
11
|
+
- Align: rank/axis alignment for specific node groups
|
|
12
|
+
|
|
13
|
+
Users can write custom constraints in ~3 lines by following this protocol.
|
|
14
|
+
"""
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
"""Core optimization loop — the heart of dagua (~200 lines of PyTorch).
|
|
2
|
+
|
|
3
|
+
Takes edge_index, node_sizes, groups as tensors (NOT a Graph object).
|
|
4
|
+
Initializes positions as learnable parameters, runs optimization with
|
|
5
|
+
composite loss from constraints, returns detached position tensor.
|
|
6
|
+
|
|
7
|
+
Headless design: independently testable without the Graph abstraction.
|
|
8
|
+
"""
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: dagua
|
|
3
|
+
Version: 0.0.0
|
|
4
|
+
Summary: GPU-accelerated differentiable graph layout engine built on PyTorch
|
|
5
|
+
Author: John Mark Taylor
|
|
6
|
+
License-Expression: MIT
|
|
7
|
+
Project-URL: Homepage, https://github.com/johnmarktaylor91/dagua
|
|
8
|
+
Project-URL: Repository, https://github.com/johnmarktaylor91/dagua
|
|
9
|
+
Project-URL: Issues, https://github.com/johnmarktaylor91/dagua/issues
|
|
10
|
+
Keywords: graph,layout,visualization,pytorch,dag,graphviz,hierarchical
|
|
11
|
+
Classifier: Development Status :: 2 - Pre-Alpha
|
|
12
|
+
Classifier: Intended Audience :: Developers
|
|
13
|
+
Classifier: Intended Audience :: Science/Research
|
|
14
|
+
Classifier: Programming Language :: Python :: 3
|
|
15
|
+
Classifier: Programming Language :: Python :: 3.9
|
|
16
|
+
Classifier: Programming Language :: Python :: 3.10
|
|
17
|
+
Classifier: Programming Language :: Python :: 3.11
|
|
18
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
19
|
+
Classifier: Topic :: Scientific/Engineering :: Visualization
|
|
20
|
+
Classifier: Topic :: Software Development :: Libraries :: Python Modules
|
|
21
|
+
Requires-Python: >=3.9
|
|
22
|
+
Description-Content-Type: text/markdown
|
|
23
|
+
License-File: LICENSE
|
|
24
|
+
Requires-Dist: torch>=1.9
|
|
25
|
+
Provides-Extra: render
|
|
26
|
+
Requires-Dist: matplotlib>=3.5; extra == "render"
|
|
27
|
+
Provides-Extra: graphviz
|
|
28
|
+
Requires-Dist: graphviz>=0.20; extra == "graphviz"
|
|
29
|
+
Provides-Extra: dev
|
|
30
|
+
Requires-Dist: matplotlib>=3.5; extra == "dev"
|
|
31
|
+
Requires-Dist: pytest>=7.0; extra == "dev"
|
|
32
|
+
Requires-Dist: pytest-cov; extra == "dev"
|
|
33
|
+
Requires-Dist: ruff>=0.4; extra == "dev"
|
|
34
|
+
Requires-Dist: mypy; extra == "dev"
|
|
35
|
+
Requires-Dist: pip-audit; extra == "dev"
|
|
36
|
+
Requires-Dist: pre-commit; extra == "dev"
|
|
37
|
+
Provides-Extra: test
|
|
38
|
+
Requires-Dist: pytest>=7.0; extra == "test"
|
|
39
|
+
Requires-Dist: matplotlib>=3.5; extra == "test"
|
|
40
|
+
Dynamic: license-file
|
|
41
|
+
|
|
42
|
+
# dagua
|
|
43
|
+
|
|
44
|
+
GPU-accelerated differentiable graph layout engine built on PyTorch.
|
|
45
|
+
|
|
46
|
+
**DAG + agua.** Directed acyclic graphs + water. Named after the Dagua River in Colombia — a river flows downhill (like a DAG), never cycles back (acyclic), and finds its own path through the landscape (like gradient descent finding optimal node positions).
|
|
47
|
+
|
|
48
|
+
## Why?
|
|
49
|
+
|
|
50
|
+
Graphviz has dominated graph visualization for 30 years but has hard scaling limits. No existing Python package provides pip-installable, hierarchical (Sugiyama-style) graph layout. Dagua fills this gap: `pip install dagua`, pure Python + PyTorch, GPU-accelerated, hierarchical layout with composable constraints.
|
|
51
|
+
|
|
52
|
+
## Status
|
|
53
|
+
|
|
54
|
+
Pre-alpha. Under active development.
|
|
55
|
+
|
|
56
|
+
## License
|
|
57
|
+
|
|
58
|
+
MIT
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
LICENSE
|
|
2
|
+
README.md
|
|
3
|
+
pyproject.toml
|
|
4
|
+
dagua/__init__.py
|
|
5
|
+
dagua/defaults.py
|
|
6
|
+
dagua/elements.py
|
|
7
|
+
dagua/graph.py
|
|
8
|
+
dagua/io.py
|
|
9
|
+
dagua/routing.py
|
|
10
|
+
dagua/style.py
|
|
11
|
+
dagua/utils.py
|
|
12
|
+
dagua.egg-info/PKG-INFO
|
|
13
|
+
dagua.egg-info/SOURCES.txt
|
|
14
|
+
dagua.egg-info/dependency_links.txt
|
|
15
|
+
dagua.egg-info/requires.txt
|
|
16
|
+
dagua.egg-info/top_level.txt
|
|
17
|
+
dagua/layout/__init__.py
|
|
18
|
+
dagua/layout/constraints.py
|
|
19
|
+
dagua/layout/engine.py
|
|
20
|
+
dagua/layout/projection.py
|
|
21
|
+
dagua/layout/schedule.py
|
|
22
|
+
dagua/render/__init__.py
|
|
23
|
+
dagua/render/graphviz.py
|
|
24
|
+
dagua/render/mpl.py
|
|
25
|
+
dagua/render/svg.py
|
|
26
|
+
tests/test_elements.py
|
|
27
|
+
tests/test_graph.py
|
|
28
|
+
tests/test_io.py
|
|
29
|
+
tests/test_routing.py
|
|
30
|
+
tests/test_style.py
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
dagua
|
|
@@ -0,0 +1,107 @@
|
|
|
1
|
+
[build-system]
|
|
2
|
+
requires = ["setuptools>=64"]
|
|
3
|
+
build-backend = "setuptools.build_meta"
|
|
4
|
+
|
|
5
|
+
[project]
|
|
6
|
+
name = "dagua"
|
|
7
|
+
version = "0.0.0"
|
|
8
|
+
description = "GPU-accelerated differentiable graph layout engine built on PyTorch"
|
|
9
|
+
readme = "README.md"
|
|
10
|
+
license = "MIT"
|
|
11
|
+
requires-python = ">=3.9"
|
|
12
|
+
authors = [
|
|
13
|
+
{name = "John Mark Taylor"},
|
|
14
|
+
]
|
|
15
|
+
keywords = ["graph", "layout", "visualization", "pytorch", "dag", "graphviz", "hierarchical"]
|
|
16
|
+
classifiers = [
|
|
17
|
+
"Development Status :: 2 - Pre-Alpha",
|
|
18
|
+
"Intended Audience :: Developers",
|
|
19
|
+
"Intended Audience :: Science/Research",
|
|
20
|
+
"Programming Language :: Python :: 3",
|
|
21
|
+
"Programming Language :: Python :: 3.9",
|
|
22
|
+
"Programming Language :: Python :: 3.10",
|
|
23
|
+
"Programming Language :: Python :: 3.11",
|
|
24
|
+
"Programming Language :: Python :: 3.12",
|
|
25
|
+
"Topic :: Scientific/Engineering :: Visualization",
|
|
26
|
+
"Topic :: Software Development :: Libraries :: Python Modules",
|
|
27
|
+
]
|
|
28
|
+
dependencies = [
|
|
29
|
+
"torch>=1.9",
|
|
30
|
+
]
|
|
31
|
+
|
|
32
|
+
[project.optional-dependencies]
|
|
33
|
+
render = ["matplotlib>=3.5"]
|
|
34
|
+
graphviz = ["graphviz>=0.20"]
|
|
35
|
+
dev = [
|
|
36
|
+
"matplotlib>=3.5",
|
|
37
|
+
"pytest>=7.0",
|
|
38
|
+
"pytest-cov",
|
|
39
|
+
"ruff>=0.4",
|
|
40
|
+
"mypy",
|
|
41
|
+
"pip-audit",
|
|
42
|
+
"pre-commit",
|
|
43
|
+
]
|
|
44
|
+
test = [
|
|
45
|
+
"pytest>=7.0",
|
|
46
|
+
"matplotlib>=3.5",
|
|
47
|
+
]
|
|
48
|
+
|
|
49
|
+
[project.urls]
|
|
50
|
+
Homepage = "https://github.com/johnmarktaylor91/dagua"
|
|
51
|
+
Repository = "https://github.com/johnmarktaylor91/dagua"
|
|
52
|
+
Issues = "https://github.com/johnmarktaylor91/dagua/issues"
|
|
53
|
+
|
|
54
|
+
[tool.setuptools.packages.find]
|
|
55
|
+
include = ["dagua*"]
|
|
56
|
+
|
|
57
|
+
[tool.pytest.ini_options]
|
|
58
|
+
testpaths = ["tests"]
|
|
59
|
+
markers = [
|
|
60
|
+
"smoke: quick sanity checks",
|
|
61
|
+
"slow: tests that take >10s",
|
|
62
|
+
"gpu: tests requiring CUDA",
|
|
63
|
+
]
|
|
64
|
+
|
|
65
|
+
[tool.coverage.run]
|
|
66
|
+
source = ["dagua"]
|
|
67
|
+
branch = true
|
|
68
|
+
|
|
69
|
+
[tool.coverage.report]
|
|
70
|
+
show_missing = true
|
|
71
|
+
skip_empty = true
|
|
72
|
+
|
|
73
|
+
[tool.coverage.html]
|
|
74
|
+
directory = "tests/test_outputs/reports/coverage_html"
|
|
75
|
+
|
|
76
|
+
[tool.coverage.lcov]
|
|
77
|
+
output = "tests/test_outputs/coverage.lcov"
|
|
78
|
+
|
|
79
|
+
[tool.mypy]
|
|
80
|
+
python_version = "3.11"
|
|
81
|
+
warn_return_any = false
|
|
82
|
+
warn_unused_configs = true
|
|
83
|
+
ignore_missing_imports = true
|
|
84
|
+
check_untyped_defs = false
|
|
85
|
+
disallow_untyped_defs = false
|
|
86
|
+
|
|
87
|
+
[tool.ruff]
|
|
88
|
+
line-length = 100
|
|
89
|
+
target-version = "py39"
|
|
90
|
+
|
|
91
|
+
[tool.ruff.lint]
|
|
92
|
+
select = ["E", "F", "W", "I"]
|
|
93
|
+
|
|
94
|
+
[tool.semantic_release]
|
|
95
|
+
version_toml = ["pyproject.toml:project.version"]
|
|
96
|
+
version_variables = ["dagua/__init__.py:__version__"]
|
|
97
|
+
branch = "main"
|
|
98
|
+
major_on_zero = true
|
|
99
|
+
build_command = "pip install build && python -m build"
|
|
100
|
+
commit_message = "chore(release): {version}"
|
|
101
|
+
|
|
102
|
+
[tool.semantic_release.remote]
|
|
103
|
+
type = "github"
|
|
104
|
+
token = { env = "GH_TOKEN" }
|
|
105
|
+
|
|
106
|
+
[tool.semantic_release.publish]
|
|
107
|
+
upload_to_vcs_release = true
|
dagua-0.0.0/setup.cfg
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"""Tests for Node, Edge, Cluster dataclasses."""
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"""Tests for Graph class — construction, ID mapping, orchestration."""
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"""Tests for io.py — from_edges, from_edge_index, from_networkx, to_dot."""
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"""Tests for bezier edge routing."""
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"""Tests for NodeStyle, EdgeStyle, ClusterStyle, themes."""
|