-
Notifications
You must be signed in to change notification settings - Fork 363
Adds basic scripting support #81
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
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
aten::addm op that can be expanded by a later pass Signed-off-by: Naren Dasan <[email protected]> Signed-off-by: Naren Dasan <[email protected]>
Signed-off-by: Naren Dasan <[email protected]> Signed-off-by: Naren Dasan <[email protected]>
Signed-off-by: Naren Dasan <[email protected]> Signed-off-by: Naren Dasan <[email protected]>
Signed-off-by: Naren Dasan <[email protected]> Signed-off-by: Naren Dasan <[email protected]>
late pass to run) Signed-off-by: Naren Dasan <[email protected]> Signed-off-by: Naren Dasan <[email protected]>
Signed-off-by: Naren Dasan <[email protected]> Signed-off-by: Naren Dasan <[email protected]>
evaluators. This allows developers to specifically blacklist or whiteline specific cases of node kinds so that they will run on a subset of cases instead of any instance. This is important in the case of prim::Loop where we want to evaluate some loops and not others. This also lets us use function schemas to target node, for instance there is now a aten::mul.Tensor converter and an aten::mul.int evaluator. In Tensor cases the converter will be called, in int cases the evaluator will. We cannot switch to keying on function schema like we do for converters because some node kinds dont have a schema so we do schema white listing instead. This commit also adds the following evaluators: - aten::mul.int - aten::sub.int - aten::__round_to_zero_floordiv - aten::slice.t - aten::len.t - prim::min.self_int Signed-off-by: Naren Dasan <[email protected]> Signed-off-by: Naren Dasan <[email protected]>
favor of an evaluator. Also fixes a bunch of bugs with the evaluators Signed-off-by: Naren Dasan <[email protected]> Signed-off-by: Naren Dasan <[email protected]>
transpose instead of conv Signed-off-by: Naren Dasan <[email protected]> Signed-off-by: Naren Dasan <[email protected]>
Signed-off-by: Naren Dasan <[email protected]> Signed-off-by: Naren Dasan <[email protected]>
ops Adds support for: - prim::shape - aten::neg - aten::add - aten::__getitem__ - aten::append Fixes: - prim::min Removes: - prim::Loop Signed-off-by: Naren Dasan <[email protected]>
Note: This is ungaurded currently, loops either must be able to be evaluated at compile time or the module is not supported. Upcomming work on RNNs will add support for more types of loops Signed-off-by: Naren Dasan <[email protected]> Signed-off-by: Naren Dasan <[email protected]>
(methods prefixed with _) Signed-off-by: Naren Dasan <[email protected]> Signed-off-by: Naren Dasan <[email protected]>
Signed-off-by: Naren Dasan <[email protected]> Signed-off-by: Naren Dasan <[email protected]>
Signed-off-by: Naren Dasan <[email protected]> Signed-off-by: Naren Dasan <[email protected]>
Signed-off-by: Naren Dasan <[email protected]> Signed-off-by: Naren Dasan <[email protected]>
Signed-off-by: Naren Dasan <[email protected]> Signed-off-by: Naren Dasan <[email protected]>
Signed-off-by: Naren Dasan <[email protected]> Signed-off-by: Naren Dasan <[email protected]>
frank-wei
pushed a commit
that referenced
this pull request
Jun 4, 2022
Summary: Pull Request resolved: https://github.com/pytorch/fx2trt/pull/81 The observer.observe calling signature is observe(module, inputs). But doing partial(observe, inputs) will reverse the order to observe(inputs, module). Fixing it by using an explicit lambda. Reviewed By: wushirong Differential Revision: D36638291 fbshipit-source-id: 64abc0952802d5b438e1013c5ff91a57442900d9
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
component: conversion
Issues re: Conversion stage
component: converters
Issues re: Specific op converters
component: evaluators
Issues re: Specific op evaluators
component: lowering
Issues re: The lowering / preprocessing passes
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
This PR will add support for scripted feed forward models like ResNet and MobileNet. It also changes how the evaluator system works, now you can set filters on evaluators to limit their scope which we use to separate loops we want to evaluate from loops we want to convert.
New support for:
New lowering pass for:
Closes #16
Type of change
Please delete options that are not relevant and/or add your own.
Checklist:
make html
in docsrc)