-
Notifications
You must be signed in to change notification settings - Fork 479
/
pyproject.toml
170 lines (139 loc) · 4.08 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
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
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
[build-system]
requires = ["setuptools", "numpy", "Cython"]
build-backend = "setuptools.build_meta"
[project]
name = "infinigen"
readme = "README.md"
license = {file = "LICENSE"}
dynamic = ["version"]
description = "Infinite Photorealistic Worlds using Procedural Generation"
keywords = [
"computer vision",
"data generation",
"procedural"
]
classifiers = [
"Framework :: Blender",
"Programming Language :: Python :: 3",
]
requires-python = "==3.11.*"
dependencies = [
"bpy==4.2.0",
"gin_config>=0.5.0",
"imageio",
"matplotlib",
"networkx",
"numpy<2",
"opencv-python",
"pandas",
"psutil",
"scikit-image",
"scikit-learn",
"scipy",
"shapely",
"tqdm",
"trimesh",
"OpenEXR",
"submitit", # can be removed so long as you dont use slurm.gin or --slurm args
"geomdl", # can be removed so long as you do not generate any creatures
# used by trimesh, we could specify "trimesh[easy]" but this brings more packages
"python-fcl",
"rtree",
]
[project.optional-dependencies]
terrain = [
"landlab==2.6.0",
"pyrender",
]
vis = [
"einops",
"flow_vis",
"numba", # for ground truth visuals
"pyglet<2" # for trimesh_scene.show()
]
dev = [
"pytest",
"pytest-ordering",
"pytest-cov",
"pytest-xdist",
"pytest-timeout",
"pytype",
"ruff",
"isort",
"tabulate",
"rapidfuzz",
"pre-commit"
]
wandb = [
"wandb"
]
[tool.setuptools]
# include-package-data is terribly named. package-data is still included if false,
# just not the package-data setuptools would otherwise autogenerate from MANIFEST.in or version control
include-package-data = false
[tool.setuptools.packages.find]
include = ["infinigen*"]
# must be specified as module paths with ., using classic filepaths with / will silently not do anything
exclude = [
"infinigen.datagen.customgt.dependencies*",
"infinigen.datagen.customgt.build*",
]
[tool.setuptools.package-data]
"*" = ["*.gin", "*.txt", "*.json"]
# Must be specified as paths relative to infinigen/
"infinigen" = [
"terrain/**/*.soil", # extra files for SoilMachine
"terrain/lib/**/*.so", # created by terrain compilation
"terrain/lib/**/*.o", # created by terrain compilation
"datagen/customgt/build/customgt", # created during opengl compilation
"assets/objects/creatures/parts/nurbs_data/*.npy", # stores creature nurbs centroids data, ideally will be deprecated
]
[tool.setuptools.dynamic]
version = {attr = "infinigen.__version__"}
[tool.pytest.ini_options]
testpaths = "tests"
junit_family = "xunit2"
markers = ["nature", "indoors", "skip_for_ci"]
timeout = 240
filterwarnings = [
"ignore:The value of the smallest subnormal for <class 'numpy.float:UserWarning",
# ignore warnings from landlab, not our problem
"ignore:pkg_resources is deprecated as an API:DeprecationWarning",
"ignore:Importing from numpy.matlib is deprecated since 1.19.0:PendingDeprecationWarning",
"ignore:Please import `label` from the `scipy.ndimage` namespace; the `scipy.ndimage.measurements` namespace is deprecated and will be removed in SciPy 2.0.0:DeprecationWarning"
]
[tool.cibuildwheel]
test-extras = ["dev"]
test-command = "pytest tests"
[tool.ruff]
target-version = "py310"
exclude = [
"*.ipynb",
# exclude known submodules
"infinigen/datagen/customgt/dependencies/",
"infinigen/OcMesher",
"infinigen/infinigen_gpl",
# exclude copied-in external code
"infinigen/terrain/mesh_to_sdf",
"infinigen/terrain/mesher/_marching_cubes_lewiner*"
]
[tool.ruff.lint]
select = [
"E",
"I",
"F",
"S102", # no exec(),
"TID252", # relative imports only allowed for siblings
]
ignore = [
"E501", # over-length lines, formatter should handle it
"E741", # ambigous variable name
]
[tool.ruff.lint.per-file-ignores]
"**/__init__.py" = [
"F401",
"CPY001", # runs during PRs, but no need for copyright on boilerplate/often-empty __init__.py
]
"infinigen/assets/*" = ["F841"] #transpiler currently creates lots of unused variables
[tool.pytype]
inputs = ['infinigen', 'infinigen_examples']