Skip to content

Commit 1d8e94b

Browse files
committed
Fix for type check in quantized cpu ops
1 parent 5797608 commit 1d8e94b

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

kernels/quantized/cpu/op_dequantize.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -384,6 +384,7 @@ Tensor& dequantize_per_channel_out(
384384
if (opt_zero_points.has_value()) {
385385
auto zero_point = opt_zero_points.value();
386386
ET_CHECK_MSG(
387+
zero_point.scalar_type() == ScalarType::Int ||
387388
zero_point.scalar_type() == ScalarType::Long,
388389
"zero_point.scalar_type() %" PRId8 " is not integer type",
389390
static_cast<int8_t>(zero_point.scalar_type()));

0 commit comments

Comments
 (0)