Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
chenpangpang
diffusers
Commits
29ad75dc
Unverified
Commit
29ad75dc
authored
May 05, 2023
by
Patrick von Platen
Committed by
GitHub
May 05, 2023
Browse files
[Quality] Make style (#3341)
parent
379197a2
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
5 additions
and
3 deletions
+5
-3
setup.py
setup.py
+2
-1
src/diffusers/dependency_versions_table.py
src/diffusers/dependency_versions_table.py
+1
-0
src/diffusers/pipelines/deepfloyd_if/pipeline_if_img2img_superresolution.py
...lines/deepfloyd_if/pipeline_if_img2img_superresolution.py
+1
-1
src/diffusers/pipelines/deepfloyd_if/pipeline_if_inpainting_superresolution.py
...es/deepfloyd_if/pipeline_if_inpainting_superresolution.py
+1
-1
No files found.
setup.py
View file @
29ad75dc
...
@@ -111,6 +111,7 @@ _deps = [
...
@@ -111,6 +111,7 @@ _deps = [
"torch>=1.4"
,
"torch>=1.4"
,
"torchvision"
,
"torchvision"
,
"transformers>=4.25.1"
,
"transformers>=4.25.1"
,
"urllib3<=2.0.0"
,
]
]
# this is a lookup table with items like:
# this is a lookup table with items like:
...
@@ -181,7 +182,7 @@ extras = {}
...
@@ -181,7 +182,7 @@ extras = {}
extras
=
{}
extras
=
{}
extras
[
"quality"
]
=
deps_list
(
"black"
,
"isort"
,
"ruff"
,
"hf-doc-builder"
)
extras
[
"quality"
]
=
deps_list
(
"urllib3"
,
"black"
,
"isort"
,
"ruff"
,
"hf-doc-builder"
)
extras
[
"docs"
]
=
deps_list
(
"hf-doc-builder"
)
extras
[
"docs"
]
=
deps_list
(
"hf-doc-builder"
)
extras
[
"training"
]
=
deps_list
(
"accelerate"
,
"datasets"
,
"protobuf"
,
"tensorboard"
,
"Jinja2"
)
extras
[
"training"
]
=
deps_list
(
"accelerate"
,
"datasets"
,
"protobuf"
,
"tensorboard"
,
"Jinja2"
)
extras
[
"test"
]
=
deps_list
(
extras
[
"test"
]
=
deps_list
(
...
...
src/diffusers/dependency_versions_table.py
View file @
29ad75dc
...
@@ -35,4 +35,5 @@ deps = {
...
@@ -35,4 +35,5 @@ deps = {
"torch"
:
"torch>=1.4"
,
"torch"
:
"torch>=1.4"
,
"torchvision"
:
"torchvision"
,
"torchvision"
:
"torchvision"
,
"transformers"
:
"transformers>=4.25.1"
,
"transformers"
:
"transformers>=4.25.1"
,
"urllib3"
:
"urllib3<=2.0.0"
,
}
}
src/diffusers/pipelines/deepfloyd_if/pipeline_if_img2img_superresolution.py
View file @
29ad75dc
...
@@ -762,7 +762,7 @@ class IFImg2ImgSuperResolutionPipeline(DiffusionPipeline):
...
@@ -762,7 +762,7 @@ class IFImg2ImgSuperResolutionPipeline(DiffusionPipeline):
image
=
[
np
.
array
(
i
).
astype
(
np
.
float32
)
/
255.0
for
i
in
image
]
image
=
[
np
.
array
(
i
).
astype
(
np
.
float32
)
/
255.0
for
i
in
image
]
image
=
np
.
stack
(
image
,
axis
=
0
)
# to np
image
=
np
.
stack
(
image
,
axis
=
0
)
# to np
torch
.
from_numpy
(
image
.
transpose
(
0
,
3
,
1
,
2
))
image
=
torch
.
from_numpy
(
image
.
transpose
(
0
,
3
,
1
,
2
))
elif
isinstance
(
image
[
0
],
np
.
ndarray
):
elif
isinstance
(
image
[
0
],
np
.
ndarray
):
image
=
np
.
stack
(
image
,
axis
=
0
)
# to np
image
=
np
.
stack
(
image
,
axis
=
0
)
# to np
if
image
.
ndim
==
5
:
if
image
.
ndim
==
5
:
...
...
src/diffusers/pipelines/deepfloyd_if/pipeline_if_inpainting_superresolution.py
View file @
29ad75dc
...
@@ -798,7 +798,7 @@ class IFInpaintingSuperResolutionPipeline(DiffusionPipeline):
...
@@ -798,7 +798,7 @@ class IFInpaintingSuperResolutionPipeline(DiffusionPipeline):
image
=
[
np
.
array
(
i
).
astype
(
np
.
float32
)
/
255.0
for
i
in
image
]
image
=
[
np
.
array
(
i
).
astype
(
np
.
float32
)
/
255.0
for
i
in
image
]
image
=
np
.
stack
(
image
,
axis
=
0
)
# to np
image
=
np
.
stack
(
image
,
axis
=
0
)
# to np
torch
.
from_numpy
(
image
.
transpose
(
0
,
3
,
1
,
2
))
image
=
torch
.
from_numpy
(
image
.
transpose
(
0
,
3
,
1
,
2
))
elif
isinstance
(
image
[
0
],
np
.
ndarray
):
elif
isinstance
(
image
[
0
],
np
.
ndarray
):
image
=
np
.
stack
(
image
,
axis
=
0
)
# to np
image
=
np
.
stack
(
image
,
axis
=
0
)
# to np
if
image
.
ndim
==
5
:
if
image
.
ndim
==
5
:
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment