mirror of
https://github.com/finegrain-ai/refiners.git
synced 2024-11-09 23:12:02 +00:00
test_concepts: silent static type checker error
This commit is contained in:
parent
f37f25a2e4
commit
63f5723449
|
@ -44,8 +44,9 @@ def our_encoder_with_new_concepts(
|
||||||
@pytest.fixture(scope="module")
|
@pytest.fixture(scope="module")
|
||||||
def ref_sd15_with_new_concepts(
|
def ref_sd15_with_new_concepts(
|
||||||
runwayml_weights_path: Path, test_textual_inversion_path: Path, test_device: torch.device
|
runwayml_weights_path: Path, test_textual_inversion_path: Path, test_device: torch.device
|
||||||
):
|
) -> StableDiffusionPipeline:
|
||||||
pipe = StableDiffusionPipeline.from_pretrained(runwayml_weights_path).to(test_device) # type: ignore
|
pipe = StableDiffusionPipeline.from_pretrained(runwayml_weights_path).to(test_device) # type: ignore
|
||||||
|
assert isinstance(pipe, StableDiffusionPipeline)
|
||||||
pipe.load_textual_inversion(test_textual_inversion_path / "cat-toy") # type: ignore
|
pipe.load_textual_inversion(test_textual_inversion_path / "cat-toy") # type: ignore
|
||||||
pipe.load_textual_inversion(test_textual_inversion_path / "gta5-artwork") # type: ignore
|
pipe.load_textual_inversion(test_textual_inversion_path / "gta5-artwork") # type: ignore
|
||||||
return pipe
|
return pipe
|
||||||
|
|
Loading…
Reference in a new issue