Allow standalone --cpu-memory
I think that what I am doing probably makes sense, but I could be wrong.
This commit is contained in:
parent
efb0ab502e
commit
d4a0b377ab
1 changed files with 1 additions and 1 deletions
|
@ -77,7 +77,7 @@ def load_model(model_name):
|
||||||
t0 = time.time()
|
t0 = time.time()
|
||||||
|
|
||||||
# Default settings
|
# Default settings
|
||||||
if not (args.cpu or args.load_in_8bit or args.auto_devices or args.disk or args.gpu_memory is not None):
|
if not (args.cpu or args.load_in_8bit or args.auto_devices or args.disk or args.gpu_memory is not None or args.cpu_memory is not None):
|
||||||
if Path(f"torch-dumps/{model_name}.pt").exists():
|
if Path(f"torch-dumps/{model_name}.pt").exists():
|
||||||
print("Loading in .pt format...")
|
print("Loading in .pt format...")
|
||||||
model = torch.load(Path(f"torch-dumps/{model_name}.pt"))
|
model = torch.load(Path(f"torch-dumps/{model_name}.pt"))
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue