fix bug when falling back to acc32 when weight is prepacked (#18881)
authorSummer Deng <summerdeng@fb.com>
Fri, 5 Apr 2019 19:44:09 +0000 (12:44 -0700)
committerFacebook Github Bot <facebook-github-bot@users.noreply.github.com>
Fri, 5 Apr 2019 20:00:26 +0000 (13:00 -0700)
commit28990f34d989da98e2cce3e38d7842049735fb97
tree93e70ffaf77133a7c316a4397acd1c874f6cd137
parentc1790fa202f30e3aca1d1ecb31f26e0b3bb1e69f
fix bug when falling back to acc32 when weight is prepacked (#18881)

Summary:
Pull Request resolved: https://github.com/pytorch/pytorch/pull/18881

Pull Request resolved: https://github.com/pytorch/pytorch/pull/18878

When the weight is prepacked and it doesn't contain a prepacked weight for acc32, we shouldn't fallback to acc32.

TODO: add unit tests with better coverage

Reviewed By: feiyu1990

Differential Revision: D14778810

fbshipit-source-id: d49a8c4b7c815ab29b77feb53ee730ad63780488
caffe2/quantization/server/conv_dnnlowp_acc16_op.cc
caffe2/quantization/server/conv_dnnlowp_acc16_op_test.py
caffe2/quantization/server/conv_groupwise_dnnlowp_acc16_op_test.py
caffe2/quantization/server/fbgemm_pack_op.cc