Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
renzhc
diffusers_dcu
Commits
1477865e
Unverified
Commit
1477865e
authored
Nov 10, 2023
by
Sayak Paul
Committed by
GitHub
Nov 10, 2023
Browse files
post release v0.23.0 (#5730)
* post release * fix: variant test * up * fix: test
parent
1f87f83e
Changes
28
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
13 additions
and
27 deletions
+13
-27
examples/textual_inversion/textual_inversion.py
examples/textual_inversion/textual_inversion.py
+1
-1
examples/textual_inversion/textual_inversion_flax.py
examples/textual_inversion/textual_inversion_flax.py
+1
-1
examples/unconditional_image_generation/train_unconditional.py
...les/unconditional_image_generation/train_unconditional.py
+1
-1
examples/wuerstchen/text_to_image/train_text_to_image_lora_prior.py
...uerstchen/text_to_image/train_text_to_image_lora_prior.py
+1
-1
examples/wuerstchen/text_to_image/train_text_to_image_prior.py
...les/wuerstchen/text_to_image/train_text_to_image_prior.py
+1
-1
setup.py
setup.py
+1
-1
src/diffusers/__init__.py
src/diffusers/__init__.py
+1
-1
tests/pipelines/test_pipelines.py
tests/pipelines/test_pipelines.py
+6
-20
No files found.
examples/textual_inversion/textual_inversion.py
View file @
1477865e
...
...
@@ -79,7 +79,7 @@ else:
# Will error if the minimal version of diffusers is not installed. Remove at your own risks.
check_min_version
(
"0.2
3
.0.dev0"
)
check_min_version
(
"0.2
4
.0.dev0"
)
logger
=
get_logger
(
__name__
)
...
...
examples/textual_inversion/textual_inversion_flax.py
View file @
1477865e
...
...
@@ -56,7 +56,7 @@ else:
# ------------------------------------------------------------------------------
# Will error if the minimal version of diffusers is not installed. Remove at your own risks.
check_min_version
(
"0.2
3
.0.dev0"
)
check_min_version
(
"0.2
4
.0.dev0"
)
logger
=
logging
.
getLogger
(
__name__
)
...
...
examples/unconditional_image_generation/train_unconditional.py
View file @
1477865e
...
...
@@ -29,7 +29,7 @@ from diffusers.utils.import_utils import is_xformers_available
# Will error if the minimal version of diffusers is not installed. Remove at your own risks.
check_min_version
(
"0.2
3
.0.dev0"
)
check_min_version
(
"0.2
4
.0.dev0"
)
logger
=
get_logger
(
__name__
,
log_level
=
"INFO"
)
...
...
examples/wuerstchen/text_to_image/train_text_to_image_lora_prior.py
View file @
1477865e
...
...
@@ -50,7 +50,7 @@ if is_wandb_available():
# Will error if the minimal version of diffusers is not installed. Remove at your own risks.
check_min_version
(
"0.2
3
.0.dev0"
)
check_min_version
(
"0.2
4
.0.dev0"
)
logger
=
get_logger
(
__name__
,
log_level
=
"INFO"
)
...
...
examples/wuerstchen/text_to_image/train_text_to_image_prior.py
View file @
1477865e
...
...
@@ -51,7 +51,7 @@ if is_wandb_available():
# Will error if the minimal version of diffusers is not installed. Remove at your own risks.
check_min_version
(
"0.2
3
.0.dev0"
)
check_min_version
(
"0.2
4
.0.dev0"
)
logger
=
get_logger
(
__name__
,
log_level
=
"INFO"
)
...
...
setup.py
View file @
1477865e
...
...
@@ -244,7 +244,7 @@ install_requires = [
setup
(
name
=
"diffusers"
,
version
=
"0.2
3
.0.dev0"
,
# expected format is one of x.y.z.dev0, or x.y.z.rc1 or x.y.z (no to dashes, yes to dots)
version
=
"0.2
4
.0.dev0"
,
# expected format is one of x.y.z.dev0, or x.y.z.rc1 or x.y.z (no to dashes, yes to dots)
description
=
"State-of-the-art diffusion in PyTorch and JAX."
,
long_description
=
open
(
"README.md"
,
"r"
,
encoding
=
"utf-8"
).
read
(),
long_description_content_type
=
"text/markdown"
,
...
...
src/diffusers/__init__.py
View file @
1477865e
__version__
=
"0.2
3
.0.dev0"
__version__
=
"0.2
4
.0.dev0"
from
typing
import
TYPE_CHECKING
...
...
tests/pipelines/test_pipelines.py
View file @
1477865e
...
...
@@ -14,7 +14,6 @@
# limitations under the License.
import
gc
import
glob
import
json
import
os
import
random
...
...
@@ -57,7 +56,7 @@ from diffusers import (
UniPCMultistepScheduler
,
logging
,
)
from
diffusers.pipelines.pipeline_utils
import
_get_pipeline_class
,
variant_compatible_siblings
from
diffusers.pipelines.pipeline_utils
import
_get_pipeline_class
from
diffusers.schedulers.scheduling_utils
import
SCHEDULER_CONFIG_NAME
from
diffusers.utils
import
(
CONFIG_NAME
,
...
...
@@ -1505,28 +1504,15 @@ class PipelineFastTests(unittest.TestCase):
assert
sd
.
name_or_path
==
tmpdirname
def
test_
warning
_no_variant_available
(
self
):
def
test_
error
_no_variant_available
(
self
):
variant
=
"fp16"
with
self
.
assert
Warns
(
FutureWarning
)
as
warning
_context
:
cached_folder
=
StableDiffusionPipeline
.
download
(
with
self
.
assert
Raises
(
ValueError
)
as
error
_context
:
_
=
StableDiffusionPipeline
.
download
(
"hf-internal-testing/diffusers-stable-diffusion-tiny-all"
,
variant
=
variant
)
assert
"but no such modeling files are available"
in
str
(
warning_context
.
warning
)
assert
variant
in
str
(
warning_context
.
warning
)
def
get_all_filenames
(
directory
):
filenames
=
glob
.
glob
(
directory
+
"/**"
,
recursive
=
True
)
filenames
=
[
f
for
f
in
filenames
if
os
.
path
.
isfile
(
f
)]
return
filenames
filenames
=
get_all_filenames
(
str
(
cached_folder
))
all_model_files
,
variant_model_files
=
variant_compatible_siblings
(
filenames
,
variant
=
variant
)
# make sure that none of the model names are variant model names
assert
len
(
variant_model_files
)
==
0
assert
len
(
all_model_files
)
>
0
assert
"but no such modeling files are available"
in
str
(
error_context
.
exception
)
assert
variant
in
str
(
error_context
.
exception
)
def
test_pipe_to
(
self
):
unet
=
self
.
dummy_cond_unet
()
...
...
Prev
1
2
Next
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