Skip to content

Instantly share code, notes, and snippets.

View Lundez's full-sized avatar

Hampus Londögård Lundez

  • Lund, Sweden
View GitHub Profile
@Lundez
Lundez / convert_pt_to_jit_traced.py
Created May 15, 2022 18:40
PyTorch to ONNX, PyTorch to JIT Traced TorchScript
from transformers import AutoTokenizer, AutoModelForSequenceClassification
import torch
# model = torch.load("model_RTC.pth")
# model.eval()
model = Exception("Add model!")
# https://colab.research.google.com/drive/1TttL1obANbt1hpZfWSifpU4HH0qmU7tj#scrollTo=JLq7Sg-v7i_L
# must be same as expected!
dummy_input = torch.rand(1, 720, 480, 3, requires_grad=True)
@Lundez
Lundez / deepfakesafry.ipynb
Created February 1, 2022 11:53
DeepFakesAFRY.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.