Verify architecture for loaded Spandrel models

This commit is contained in:
Aarni Koskela
2023-12-30 16:37:03 +02:00
parent c756133541
commit 4ad0c0c0a8
8 changed files with 22 additions and 5 deletions

View File

@@ -37,6 +37,7 @@ class FaceRestorerGFPGAN(face_restoration_utils.CommonFaceRestoration):
net = modelloader.load_spandrel_model(
model_path,
device=self.get_device(),
expected_architecture='GFPGAN',
).model
net.different_w = True # see https://github.com/chaiNNer-org/spandrel/pull/81
return net