Repository navigation
Expand file tree
/
Copy pathpyproject.toml
More file actions
99 lines (89 loc) · 3.21 KB
/
Copy pathpyproject.toml
File metadata and controls
99 lines (89 loc) · 3.21 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
# Derived from cubiq/Mellon@5fd242921d13bff9fb03f4de405fdd39c2335e1f; modified by MoDiff.
[project]
name = "modiff"
version = "0.1.0"
description = "MoDiff is a modular Diffusers client/server application."
readme = "README.md"
license = "Apache-2.0"
requires-python = ">=3.12,<3.13"
dependencies = [
"accelerate>=1.4.0",
"aiohttp>=3.11.12",
"aiohttp-cors>=0.7.0",
"kornia>=0.8.1",
"nanoid>=2.0.0",
"peft>=0.17.0",
"protobuf>=6.31.1",
"scipy>=1.15.2",
"sentencepiece>=0.2.0",
"torch>=2.6.0",
"torchsde>=0.2.6",
"torchvision>=0.21.0",
"transformers>=4.49.0",
"diffusers @ git+https://github.com/huggingface/diffusers.git@13a7bee4878d62fccc8d25f97e480e68de96fa03",
"ftfy>=6.3.1",
"huggingface-hub>=1.23.0,<2.0",
"imageio>=2.37.2",
"imageio-ffmpeg>=0.6.0",
"spandrel>=0.4.2",
"yt-dlp>=2026.7.4",
]
[project.optional-dependencies]
apple-silicon = [
"torch>=2.6.0; sys_platform == 'darwin'",
"torchvision>=0.21.0; sys_platform == 'darwin'",
]
cuda = [
"bitsandbytes==0.50.0; sys_platform == 'linux' or sys_platform == 'win32'",
# xFormers wheels are Torch-ABI specific. 0.0.32.post2 is the upstream
# release built for the managed NVIDIA profile's Torch 2.8 runtime; allowing
# an unbounded latest release currently resolves to a Torch 2.10+ build.
"xformers==0.0.32.post2; sys_platform == 'linux' or sys_platform == 'win32'",
]
nunchaku = [
"nunchaku>=1.0.1.dev20250924; sys_platform == 'linux' or sys_platform == 'win32'"
]
spandrel = ["spandrel"]
gallery-media = ["opencv-python-headless>=4.11.0"]
quantization = [
"dfloat11[cuda12]; sys_platform == 'linux' or sys_platform == 'win32'",
"gguf",
"kernels==0.16.0",
"optimum-quanto==0.2.7",
"torchao==0.17.0",
]
[tool.ruff]
line-length = 119
[tool.ruff.lint.isort]
lines-after-imports = 2
[tool.ruff.format]
# Like Black, use double quotes for strings.
quote-style = "double"
# Like Black, indent with spaces, rather than tabs.
indent-style = "space"
[tool.setuptools.packages.find]
# MoDiff intentionally keeps both the server package and its built-in node
# modules at the repository root. Explicit discovery prevents editable
# installs from treating runtime data/web/custom directories as packages.
include = ["modiff*", "modules*"]
exclude = ["custom*", "data*", "tests*", "web*"]
[tool.uv]
# The accelerator-specific installer owns MoDiff's executable environment.
# This prevents `uv run` / `uv sync` from replacing a validated CUDA, ROCm,
# MPS, or CPU profile with the generic development resolution.
managed = false
[[tool.uv.index]]
name = "pytorch-cu128"
url = "https://download.pytorch.org/whl/cu128"
explicit = true
[tool.uv.sources]
torch = [
{ index = "pytorch-cu128", marker = "sys_platform == 'linux' or sys_platform == 'win32'" },
]
torchvision = [
{ index = "pytorch-cu128", marker = "sys_platform == 'linux' or sys_platform == 'win32'" },
]
nunchaku = [
{ url = "https://github.com/nunchaku-tech/nunchaku/releases/download/v1.0.1dev20250924/nunchaku-1.0.1.dev20250924+torch2.8-cp312-cp312-linux_x86_64.whl", marker = "sys_platform == 'linux'" },
{ url = "https://github.com/nunchaku-tech/nunchaku/releases/download/v1.0.1dev20250924/nunchaku-1.0.1.dev20250924+torch2.8-cp312-cp312-win_amd64.whl", marker = "sys_platform == 'win32'" },
]