Unverified Commit 1477865e authored by Sayak Paul's avatar Sayak Paul Committed by GitHub
Browse files

post release v0.23.0 (#5730)

* post release

* fix: variant test

* up

* fix: test
parent 1f87f83e
......@@ -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.23.0.dev0")
check_min_version("0.24.0.dev0")
logger = get_logger(__name__)
......
......@@ -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.23.0.dev0")
check_min_version("0.24.0.dev0")
logger = logging.getLogger(__name__)
......
......@@ -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.23.0.dev0")
check_min_version("0.24.0.dev0")
logger = get_logger(__name__, log_level="INFO")
......
......@@ -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.23.0.dev0")
check_min_version("0.24.0.dev0")
logger = get_logger(__name__, log_level="INFO")
......
......@@ -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.23.0.dev0")
check_min_version("0.24.0.dev0")
logger = get_logger(__name__, log_level="INFO")
......
......@@ -244,7 +244,7 @@ install_requires = [
setup(
name="diffusers",
version="0.23.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.24.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",
......
__version__ = "0.23.0.dev0"
__version__ = "0.24.0.dev0"
from typing import TYPE_CHECKING
......
......@@ -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.assertWarns(FutureWarning) as warning_context:
cached_folder = StableDiffusionPipeline.download(
with self.assertRaises(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()
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment