Skip to content

Commit

Permalink
[fix] relax QnnConv2DTransposeRel constraint (#10716)
Browse files Browse the repository at this point in the history
* zp check

* lint
  • Loading branch information
anwang2009 authored Mar 23, 2022
1 parent dbbbe4f commit 0218482
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/relay/qnn/op/convolution_transpose.cc
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,10 @@ bool QnnConv2DTransposeRel(const Array<Type>& types, int num_inputs, const Attrs
}
}
ICHECK(IsScalarType(types[2], DataType::Int(32))); // input_zero_point
ICHECK(IsScalarType(types[3], DataType::Int(32))); // weight_zero_point

const auto* weight_zp_type = types[3].as<TensorTypeNode>();
ICHECK(weight_zp_type->dtype == DataType::Int(32)); // weight_zero_point

ICHECK(IsScalarType(types[4], DataType::Float(32))); // input_scale
// Kernel scale can be a vector of length output_channels or a scalar.
if (param->groups == 1) {
Expand Down

0 comments on commit 0218482

Please sign in to comment.