Skip to content
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

[Relay] Improved multiply_rewrite for gluoncv_ssd quantization #2848

Merged
merged 2 commits into from
Mar 20, 2019

Conversation

liangfu
Copy link
Member

@liangfu liangfu commented Mar 19, 2019

@ZihengJiang @vinx13 please review.

@@ -166,7 +166,7 @@ def multiply_rewrite(ref_call, new_args, ctx):

if lhs_kind is None and rhs_kind is None:
return None
if lhs_kind == QAnnotateKind.ACTIVATION and rhs_kind is None:
if lhs_kind in [QAnnotateKind.ACTIVATION, QAnnotateKind.INPUT] and rhs_kind is None:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

add a check to attach_simulated_quantize below to prevent quantizing lhs to INPUT if lhs_kind is INPUT

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not quite familiar with this, but what shall lhs_expr be if lhs_kind is INPUT?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it is the same from input, new_args[0]

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

okay, i will revise accordingly.

@liangfu liangfu changed the title improved multiply_rewrite for gluoncv_ssd quantization [Relay] Improved multiply_rewrite for gluoncv_ssd quantization Mar 20, 2019
@tqchen tqchen merged commit 51f638c into apache:master Mar 20, 2019
Laurawly pushed a commit to Laurawly/tvm-1 that referenced this pull request Mar 22, 2019
…che#2848)

* improved `multiply_rewrite` for gluoncv_ssd quantization

* add a check to attach_simulated_quantize below to prevent quantizing lhs to INPUT if lhs_kind is INPUT;
wweic pushed a commit to wweic/tvm that referenced this pull request Mar 24, 2019
…che#2848)

* improved `multiply_rewrite` for gluoncv_ssd quantization

* add a check to attach_simulated_quantize below to prevent quantizing lhs to INPUT if lhs_kind is INPUT;
wweic pushed a commit to neo-ai/tvm that referenced this pull request Mar 24, 2019
…che#2848)

* improved `multiply_rewrite` for gluoncv_ssd quantization

* add a check to attach_simulated_quantize below to prevent quantizing lhs to INPUT if lhs_kind is INPUT;
@liangfu liangfu deleted the patch-7 branch April 14, 2020 14:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants