Ahsen Khaliq
commited on
Commit
·
4a4961c
1
Parent(s):
9e5c86d
Update psp_encoder/psp_encoders.py
Browse files
psp_encoder/psp_encoders.py
CHANGED
|
@@ -141,7 +141,7 @@ class PSPEncoder(Module):
|
|
| 141 |
print('Loading psp encoders weights from irse50!')
|
| 142 |
encoder_ckpt = torch.load(encoder_ckpt_path, map_location='cpu')
|
| 143 |
self.encoder.load_state_dict(get_keys(encoder_ckpt, 'encoder'), strict=True)
|
| 144 |
-
self.latent_avg = encoder_ckpt['latent_avg']
|
| 145 |
|
| 146 |
self.face_pool = torch.nn.AdaptiveAvgPool2d((256, 256))
|
| 147 |
|
|
|
|
| 141 |
print('Loading psp encoders weights from irse50!')
|
| 142 |
encoder_ckpt = torch.load(encoder_ckpt_path, map_location='cpu')
|
| 143 |
self.encoder.load_state_dict(get_keys(encoder_ckpt, 'encoder'), strict=True)
|
| 144 |
+
self.latent_avg = encoder_ckpt['latent_avg']
|
| 145 |
|
| 146 |
self.face_pool = torch.nn.AdaptiveAvgPool2d((256, 256))
|
| 147 |
|