Remove map_location

This commit is contained in:
henryruhs
2025-03-11 14:43:09 +01:00
parent 575f215408
commit 83ef075b1d
5 changed files with 10 additions and 10 deletions
+1 -1
View File
@@ -17,7 +17,7 @@ def export() -> None:
opset_version = CONFIG.getint('exporting', 'opset_version')
makedirs(directory_path, exist_ok = True)
state_dict = torch.load(source_path, map_location = 'cpu').get('state_dict').get('generator')
state_dict = torch.load(source_path).get('state_dict').get('generator')
model = Generator()
model.load_state_dict(state_dict)
model.eval()