simplified setup.py
This commit is contained in:
@ -75,6 +75,8 @@ def load(name: str, device: Union[str, torch.device] = "cuda" if torch.cuda.is_a
|
||||
|
||||
if not jit:
|
||||
model = build_model(model.state_dict()).to(device)
|
||||
if device == "cpu":
|
||||
model.float()
|
||||
return model, transform
|
||||
|
||||
# patch the device names
|
||||
|
Reference in New Issue
Block a user