fixed model not going to correct device
Browse files31 unmodified lines32333435363731 unmodified linesdef initialize(path="models/model.pt"):model = DistilBERTSent()model.load_state_dict(torch.load(path, map_location=device))model.eval()return model31 unmodified lines3233343536373831 unmodified linesdef initialize(path="models/model.pt"):model = DistilBERTSent()model.load_state_dict(torch.load(path, map_location=device))model.to(device)model.eval()return model
inference.py+1