-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathpyproject.toml
More file actions
145 lines (136 loc) · 4.93 KB
/
Copy pathpyproject.toml
File metadata and controls
145 lines (136 loc) · 4.93 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
[build-system]
requires = ["setuptools>=84.0.0"]
build-backend = "setuptools.build_meta"
[project]
name = "diffusers-workflow"
# The single source of the version: dw.__version__ reads it from here at
# runtime (static in TOML because importing dw at build time would drag
# torch into the build environment). Release tags must match it - see
# docs/RELEASING.md
version = "0.4.0-beta.5"
description = "Declarative workflow engine and web UI for Hugging Face Diffusers"
readme = "README.md"
requires-python = ">=3.10"
license = { text = "Apache-2.0" }
authors = [{ name = "dkackman" }]
classifiers = [
"Development Status :: 3 - Alpha",
"Intended Audience :: Developers",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
"Programming Language :: Python :: 3.14",
]
# The single source of dependencies: the wheel, requirements.txt (a pointer
# to here), install.sh, and CI all resolve this list. Torch ships CPU-only
# from PyPI on Linux - a CUDA build comes from pytorch.org's own index and
# must be installed first (install.sh does; see requirements.txt).
# Version floors track the environment the project is developed and tested
# on (see docs/DEPENDENCIES.md) - refresh them from a working venv rather
# than editing ad hoc: python scripts/refresh_dep_floors.py
dependencies = [
# Core ML frameworks
"torch>=2.13.0",
"torchvision>=0.28.0",
# Diffusers and the HuggingFace ecosystem. The floor is the newest
# PyPI release; the newest pipelines may need git HEAD on top, which
# install.sh layers on (and the web UI's Models page can install)
"diffusers>=0.40.0",
"transformers>=5.16.1",
"accelerate>=1.14.0",
"peft>=0.20.0",
"safetensors>=0.8.0",
"huggingface-hub>=1.29.0",
# Loaded at runtime by model tokenizers/text encoders, not imported here
"sentencepiece>=0.2.2",
"protobuf>=7.36.0",
"ftfy>=6.3.1",
# SDE schedulers
"torchsde>=0.2.6",
# Quantization backends (config_objects.py loads them dynamically)
"torchao>=0.18.0",
"optimum-quanto>=0.2.7",
"sdnq>=0.2.5",
"gguf>=0.19.0",
"bitsandbytes>=0.50.2; sys_platform == 'linux'",
# ControlNet preprocessors (brings opencv-headless, scikit-image,
# scipy, timm) and pipelines that want kornia
"controlnet-aux>=0.0.10",
"opencv-python-headless>=5.0.0.93",
"kornia>=0.8.3",
# Upscaling and face restoration tasks
"spandrel>=0.4.2",
"facexlib>=0.3.0",
# Imaging and media
"numpy>=2.5.2",
"Pillow>=12.3.0",
"piexif>=1.1.3",
"imageio>=2.37.4",
"imageio-ffmpeg>=0.6.0",
"av>=18.1.0",
"soundfile>=0.14.0",
"matplotlib>=3.11.1",
# Utilities
"qrcode>=8.2",
"requests>=2.34.2",
"aiohttp>=3.14.3",
"beautifulsoup4>=4.15.0",
"jsonschema>=4.26.0",
"concurrent-log-handler>=0.9.29",
"python-dotenv>=1.2.3",
"packaging>=26.3",
]
[project.optional-dependencies]
server = ["fastapi>=0.141.1", "uvicorn[standard]>=0.52.4"]
mcp = ["mcp>=2.1.1", "httpx>=0.28.1"]
dev = [
"pytest>=9.1.1",
"pytest-cov>=7.1.0",
"pytest-xdist>=3.8.0",
"pytest-timeout>=2.4.0",
"pytest-mock>=3.15.1",
"pytest-asyncio>=1.4.0",
"httpx>=0.28.1",
"ruff>=0.15.0",
"build",
"mcp>=2.1.1",
]
[project.urls]
Homepage = "https://github.com/dkackman/diffusers-workflow"
[project.scripts]
dw-run = "dw.run:main"
dw-validate = "dw.validate:main"
dw-repl = "dw.repl:main"
dw-serve = "dw.serve:main"
dw-test = "dw.test:main"
dw-mcp = "dw_mcp.__main__:main"
[tool.ruff]
target-version = "py310"
[tool.ruff.lint]
# Start conservative: pyflakes + pycodestyle only. Widen (e.g. add "I" for
# import sorting) once the existing codebase is clean under those too.
select = ["E", "F"]
# The formatter already wraps code to the line length; E501 mostly flags
# comments/strings/URLs that can't be split, so it's noise on top of that.
ignore = ["E501"]
[tool.ruff.lint.per-file-ignores]
# These import a pytest fixture by name and reuse that name as a test
# function's parameter (the idiomatic way to share a fixture across
# modules) - pyflakes/ruff can't tell that from a genuine redefinition.
"tests/test_jobs_listing.py" = ["F811"]
"tests/test_server_downloads.py" = ["F811"]
"tests/test_server_exports.py" = ["F811"]
[tool.setuptools.packages.find]
# tasks/, pipeline_processors/ and community_pipelines/ are namespace
# packages (no __init__.py) - a plain find would silently drop them
include = ["dw*"]
namespaces = true
[tool.setuptools.package-data]
dw = ["*.json", "workflows/*.json", "community_pipelines/*.py", "docs/*.md"]
# docs/ is copied in by scripts/build_dist.sh, the way the SPA is - it is what
# dw.server's list_guides/get_guide serve. A checkout has no copy and reads the
# repo's own docs/ instead
# The built SPA, copied in by scripts/build_dist.sh before packaging
"dw.server" = ["ui/**"]