-
Notifications
You must be signed in to change notification settings - Fork 151
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cannot build TensorT engine for classification models #115
Comments
Sorry for the delay, I was on vacation. Can you run the conversion with |
Hello, thank you very much for your reply. I'm sorry for the late answer, I was on vacation as well !
It seems that by using the Do you have any workaround to this so I can use the Thanks in advance for taking the time to answer ! |
Hello,
I tried to reproduce the optimization process you decribed in your
Accelerating GPT-2 model
notebook demo for optimizing a model for ONNX Runtime and Triton server, but with a classification model (namelyfacebook/bart-large-mnli
which I found on HuggingFace's hub).However I get a problem when trying to build a TensorRT engine from the corresponding ONNX file: the task fails and the resulting engine is of type
NoneType
. I also tried using the TensorRT builder'sbuild_engine
method but the result is also of typeNoneType
.After investigating a bit, I found out that this problem arises when initializing
facebook/bart-large-mnli
with theBartForSequenceClassification
class, but not when initializing it with theBartForConditionalGeneration
class, even though the model was specifically fine-tuned for the MNLI classification task.The whole code is attached in a ipynb file and I ran it using Google Colab.
Could you please help me resolve it ? Thanks in advance for your help !
Versions:
To reproduce:
model_optimization.zip
The text was updated successfully, but these errors were encountered: