-
Notifications
You must be signed in to change notification settings - Fork 526
Error running .pte model with executor_runner #8923
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
Comments
@corehalt Thanks for reporting the issue! |
Im guessing the failure is a lifted constant is getting flagged as a user input due to a bug in one of the const prop passes (why are you mixing them?). Can you share the results of print(aten_dialect_program.graph) and print(edge_dialect_program.exported_program().graph_module.graph) |
Also are you comfortable sharing the model definition? |
Tried the passes because I was trying to get rid of constants, they are not being folded (#8446), I thought it was an issue on the passes but turned out that there are many constants added in the last steps of the conversion to .pte.
@JacobSzwejbka sure, here they are: After first constant folding pass: print(aten_dialect_program.graph)
print(aten_dialect_program.graph_signature) Output:
After second constant folding pass: print(aten_dialect_program.graph)
print(aten_dialect_program.graph_signature) Output:
And edge dialect: print(edge_dialect_program.exported_program().graph_module.graph)
print(edge_dialect_program.exported_program().graph_signature) Output:
|
Oh wait the error happens after execute? I think that actually means its likely its failing inside an op somewhere. Sorry I missed that. cc @Gasoonjia do you know an easy way for someone in OSS to debug what operator is failing in mid execution? I wouldve thought some logging should appear. |
I don't think we have any specific tool to show operator failing; if ET_LOG didn't work as expected, perhaps sanity checks of some operators don't cover enough? |
@JacobSzwejbka @iseeyuan any updates on this issue? |
🐛 Describe the bug
I have exported this model:
https://github.com./corehalt/share/raw/refs/heads/main/yolov8n_runtime_issue.pte
with the following code:
Then I tried to run the model with the official C++ executor_runner and but I get the next error:
With other models and using the same code, the inference runs without problem.
I also wrote another executor based on the official one but I also get the same error there.
Other things I tried is to use
strict=False
on torch.export() but still it gives me the same error.For reference, this is the corresponding output of
torch.export.save()
:https://github.com./corehalt/share/raw/refs/heads/main/yolov8n_runtime_issue.pt2
Versions
cc @JacobSzwejbka
The text was updated successfully, but these errors were encountered: