[pytorch] remove boilerplate setQEngine() from PyTorch mobile predictors#34556
[pytorch] remove boilerplate setQEngine() from PyTorch mobile predictors#34556ljk53 wants to merge 1 commit intogh/ljk53/121/basefrom
Conversation
Summary: According to #34012 (comment), this `at::globalContext().setQEngine(at::QEngine::QNNPACK);` call isn't really necessary for mobile. In Context.cpp it selects the last available QEngine if the engine isn't set explicitly. For OSS mobile prebuild it should only include QNNPACK engine so the default behavior should already be desired behavior. It makes difference only when USE_FBGEMM is set - but it should be off for both OSS mobile build and internal mobile build. [ghstack-poisoned]
Summary: According to #34012 (comment), this `at::globalContext().setQEngine(at::QEngine::QNNPACK);` call isn't really necessary for mobile. In Context.cpp it selects the last available QEngine if the engine isn't set explicitly. For OSS mobile prebuild it should only include QNNPACK engine so the default behavior should already be desired behavior. It makes difference only when USE_FBGEMM is set - but it should be off for both OSS mobile build and internal mobile build. ghstack-source-id: 139184c Pull Request resolved: #34556
|
"In Context.cpp it selects the last available QEngine if the engine isn't We also include NNPACK for OSS build, don't know if that counted as an engine. |
ezyang
left a comment
There was a problem hiding this comment.
I don't know if it's right, but I love deleted code!
it's not counted as "q"-engine :) |
💊 CircleCI build failures summary and remediationsAs of commit 8195861 (more details on the Dr. CI page): ✅ None of the build failures appear to be your fault 💚
🚧 2 upstream failures:These were probably caused by upstream breakages:
This comment was automatically generated by Dr. CI (expand for details).Follow this link to opt-out of these comments for your Pull Requests.Please report bugs/suggestions on the GitHub issue tracker. This comment has been revised 16 times. |
…ors (pytorch#34556) Summary: Pull Request resolved: pytorch#34556 According to pytorch#34012 (comment), this `at::globalContext().setQEngine(at::QEngine::QNNPACK);` call isn't really necessary for mobile. In Context.cpp it selects the last available QEngine if the engine isn't set explicitly. For OSS mobile prebuild it should only include QNNPACK engine so the default behavior should already be desired behavior. It makes difference only when USE_FBGEMM is set - but it should be off for both OSS mobile build and internal mobile build. Test Plan: Imported from OSS Differential Revision: D20374522 Pulled By: ljk53 fbshipit-source-id: d4e437a03c6d4f939edccb5c84f02609633a0698
Stack from ghstack:
Summary:
According to
#34012 (comment),
this
at::globalContext().setQEngine(at::QEngine::QNNPACK);call isn'treally necessary for mobile.
In Context.cpp it selects the last available QEngine if the engine isn't
set explicitly. For OSS mobile prebuild it should only include QNNPACK
engine so the default behavior should already be desired behavior.
It makes difference only when USE_FBGEMM is set - but it should be off
for both OSS mobile build and internal mobile build.
Differential Revision: D20374522