Spaces:
Build error
Build error
Update app.py
Browse files
app.py
CHANGED
@@ -53,7 +53,7 @@ _ARTICLE = 'See uses.md'
|
|
53 |
|
54 |
def load_model_from_config(config, ckpt, device, verbose=False):
|
55 |
print(f'Loading model from {ckpt}')
|
56 |
-
pl_sd = torch.load(ckpt, map_location=
|
57 |
if 'global_step' in pl_sd:
|
58 |
print(f'Global Step: {pl_sd["global_step"]}')
|
59 |
sd = pl_sd['state_dict']
|
|
|
53 |
|
54 |
def load_model_from_config(config, ckpt, device, verbose=False):
|
55 |
print(f'Loading model from {ckpt}')
|
56 |
+
pl_sd = torch.load(ckpt, map_location='cpu')
|
57 |
if 'global_step' in pl_sd:
|
58 |
print(f'Global Step: {pl_sd["global_step"]}')
|
59 |
sd = pl_sd['state_dict']
|