diff options
author | C43H66N12O12S2 <36072735+C43H66N12O12S2@users.noreply.github.com> | 2022-09-12 16:26:42 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-09-12 16:26:42 +0300 |
commit | fbeadef1308a551aead705024df86c51242e7e62 (patch) | |
tree | a5cd3b2e754419df92583cb35325701ee2394a4a /webui.py | |
parent | 11e648f6c75de2fb22460d34a618dbb3aa6df0bc (diff) |
webui.py channels last support
Diffstat (limited to 'webui.py')
-rw-r--r-- | webui.py | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -49,7 +49,8 @@ def load_model_from_config(config, ckpt, verbose=False): if len(u) > 0 and verbose:
print("unexpected keys:")
print(u)
-
+ if cmd_opts.channelslast:
+ model = model.to(memory_format=torch.channels_last)
model.eval()
return model
|