Skip to content

Commit

Permalink
Remove unused function cal_offset_2d from QuantizationUtils
Browse files Browse the repository at this point in the history
This commit removes the function `cal_offset_2d` from QuantizationUtils.

ONE-DCO-1.0-Signed-off-by: y01000.you <[email protected]>
  • Loading branch information
y01000.you committed Nov 5, 2024
1 parent 3c96ebb commit 7789e17
Showing 1 changed file with 0 additions and 6 deletions.
6 changes: 0 additions & 6 deletions compiler/luci/pass/src/QuantizationUtils.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -292,12 +292,6 @@ uint32_t cal_offset(loco::TensorShape &dimension, uint32_t *indices)
indices[2] * dimension.dim(3).value() + indices[3];
}

uint32_t cal_offset_2d(loco::TensorShape &dimension, uint32_t indices[2])
{
assert(dimension.rank() == 2);
return indices[0] * dimension.dim(1).value() + indices[1];
}

// Activation (ofm) qtype is determined in different ways.
// 1. Pre-defined values: Some Ops have pre-defined qparams (ex: LOGISTIC, TANH)
// 2. Integer scale: Output of some Ops should be integers (ex: FLOOR, CEIL)
Expand Down

0 comments on commit 7789e17

Please sign in to comment.