未验证 提交 651aad06 编写于 作者: 王明冬 提交者: GitHub

[pass_enhance] skip the atrribute check used for quantization, test=develop (#34095)

上级 2591076c
......@@ -179,6 +179,12 @@ bool OpCompat::Judge(const OpDesc& op_desc) {
}
for (auto& attr_map : op_desc.GetAttrMap()) {
const std::string& name = attr_map.first;
if (name.size() >= 10u &&
0 == name.compare(name.size() - 10u, 10u, "_threshold")) {
continue; // skip the attribute ends with "_threshold", it used for
// quantization.
}
if (attr_compats_.find(attr_map.first) == attr_compats_.end()) {
if (global_extra_attrs.find(attr_map.first) != global_extra_attrs.end() ||
extra_attrs_.find(attr_map.first) != extra_attrs_.end()) {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册