I’m bit new in torch tensorrt, but need help with how I’m gonna run torch tensorrt on any models.
Can someone provide me with an example? I’m trying to convert hf model into torch tensorrt but couldn’t convert it successfully, here is the code please convert this code into running torch tensorrt code:
from transformers import AutoModel AutoFeatureExtractor
checkpoint_name = “microsoft/resnet-50”
feature_extractor = AutoFeatureExtractor.from_pretrained(checkpoint_name)
torch_resnet = AutoModel.from_pretrained(checkpoint_name)
x = torch.rand((1, 3, 224, 224))