Skip to content

Commit

Permalink
Merge pull request #11 from RMeli/jit
Browse files Browse the repository at this point in the history
Compile models to TorchScript
  • Loading branch information
RMeli authored Nov 17, 2021
2 parents 2e4457f + 4593d45 commit 563fe78
Show file tree
Hide file tree
Showing 4 changed files with 352 additions and 96 deletions.
4 changes: 1 addition & 3 deletions gnina/inference.py
Original file line number Diff line number Diff line change
Expand Up @@ -151,9 +151,7 @@ def inference(args):
affinity: bool = True if args.affinity_pos is not None else False

# Create model
model = models.models_dict[args.model](test_loader.dims, affinity=affinity).to(
device
)
model = models.models_dict[(args.model, affinity)](test_loader.dims).to(device)

# Load checkpoint
checkpoint = torch.load(args.checkpoint, map_location=device)
Expand Down
Loading

0 comments on commit 563fe78

Please sign in to comment.