-
Notifications
You must be signed in to change notification settings - Fork 10
/
Copy pathpyproject.toml
105 lines (91 loc) · 2.82 KB
/
pyproject.toml
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
# Note: This pyproject.toml file is intended to publish model/ folder as pip package
# and is not intended to be used for the whole project. For the project, use anaconda-project.yml
[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"
[project]
name = "ddpm"
description = "Pytorch implementation of 'Improved Denoising Diffusion Probabilistic Models', 'Denoising Diffusion Probabilistic Models' and 'Classifier-free Diffusion Guidance'"
requires-python = ">=3.7,<3.12"
keywords = ["pytorch", "ddpm", "denoising diffusion probabilistic model", "generative", ]
license = {text = "MIT"}
readme = "readme_pip.md"
classifiers = [
"Development Status :: 5 - Production/Stable",
"Intended Audience :: Developers",
"Intended Audience :: Science/Research",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
"Programming Language :: Python",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Topic :: Scientific/Engineering :: Artificial Intelligence",
"Topic :: Software Development :: Libraries :: Python Modules",
]
dependencies = [
"torch>=1.8",
"pytorch-lightning >= 1.8",
"torchvision",
"tensorguard==1.0.0",
"path>=16.0"
]
version = "1.0.0"
[project.optional-dependencies]
dev = [
"pytest",
]
[tool.hatch.build]
include = [
"ddpm",
]
[tool.hatch.envs.default]
python = "3.10"
dependencies = [
"torch==2.0.1",
"torchvision",
"pytorch-lightning",
"torchmetrics",
"torchsummary",
"path",
"numpy",
"hydra-core",
"tensorboard",
"seaborn",
"matplotlib",
"einops",
"pytest",
]
[tool.hatch.envs.default.scripts]
train = "python train.py accelerator=gpu devices=1 {args:train-gpu}"
test = "pytest {args:tests}"
compress-runs = "tar cfz saved_models.tar.gz saved_models/"
run-tensorboard = "tensorboard --logdir=saved_models/"
clean-empty-runs = """python -c '\nfrom path import Path\nfor run in Path(\"saved_models\").dirs():\n\
if not run.joinpath(\"best.ckpt\").exists():\n print(f\"Removing\
{run}\")\n run.rmtree()'\n"""
generate = "python generate.py {args:generate}"
plot-cosine-scheduler = "python plot_cosine_scheduler.py {args:plot-cosine-scheduler}"
[tool.hatch.envs.cpu]
python = "3.10"
dependencies = [
"torch==2.0.1",
"torchvision",
"pytorch-lightning",
"path",
"numpy",
"hydra-core",
"tensorboard",
"seaborn",
"matplotlib",
"einops",
"pytest",
]
[tool.hatch.envs.cpu.env-vars]
PIP_EXTRA_INDEX_URL = "https://download.pytorch.org/whl/cpu"
PIP_VERBOSE = "1"
[tool.hatch.envs.cpu.scripts]
train = "python train.py accelerator=cpu devices=1 {args:train-cpu}"