-
Notifications
You must be signed in to change notification settings - Fork 3.5k
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
[TOPI] bitserial_conv2d move to autotvm template and updates #2819
Conversation
Please request reviewers |
@eqy @ZihengJiang, please review |
policy='candidate', candidate=[ | ||
[n, oh, ow, co, vh, vw, kh, kw, ci_o, kb, ib, vc, ci_i], | ||
[n, oh, ow, co, vh, vw, kw, kh, ci_o, kb, ib, vc, ci_i],]) | ||
cfg.add_flop(2 * N * OH * OW * CO * CI * 8 * KH * KW) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does the automatic flop calculation in #2776 work for this?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sadly no :( it gives an error about multiple output in the compute.
re_axes = cfg.define_reorder("reorder_0", | ||
[n, oh, ow, co, vh, vw, kh, kw, kb, ib, vc, ci], | ||
policy='interval_all', interval=(3, 7)) | ||
cfg.add_flop(2 * N * OH * OW * CO * CI * 8 * KH * KW) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
""
re_axes = cfg.define_reorder("reorder_0", | ||
[n, co, oh, ow, vc, vh, vw, kh, kw, kb, ib, ci], | ||
policy='interval_all', interval=(6, 11)) | ||
cfg.add_flop(2 * N * OH * OW * CO * CI * 8 * KH * KW) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
""
@@ -45,6 +44,9 @@ def test_bitserial_conv2d(): | |||
verify_bitserial_conv2d_nhwc(1, in_size, ic, oc, k, stride, pad, 1, 1, False) | |||
verify_bitserial_conv2d_nhwc(1, in_size, ic, oc, k, stride, pad, 2, 1, False) | |||
|
|||
verify_bitserial_conv2d_nhwc(1, in_size, ic, oc, k, stride, pad, 1, 1, True) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is it possible to add a correctness check here for random or precomputed inputs? It looks like generate_quantized_np
is no longer used.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added, but it will only run on an arm device.
@ajtulloch @vinx13 please also help review the PR if you have time. @cowanmeg please try to rebase and fix the CI problem |
Updates to arm_cpu and x86 bitserial_conv2d operators