Skip to content

Commit c061bd5

Browse files
committed
Lint
1 parent 3f75e61 commit c061bd5

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

kernels/quantized/cpu/op_embedding.cpp

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -157,13 +157,15 @@ void embedding_byte_per_channel(
157157
// Check if index is out of bounds for both weight and weight_scales
158158
ET_CHECK_MSG(
159159
index >= 0 && index < weight.size(0),
160-
"Index out of bounds for weight: index %" PRId64 " must be in range [0, %zd)",
160+
"Index out of bounds for weight: index %" PRId64
161+
" must be in range [0, %zd)",
161162
index,
162163
weight.size(0));
163164

164165
ET_CHECK_MSG(
165166
index >= 0 && index < weight_scales.size(0),
166-
"Index out of bounds for weight_scales: index %" PRId64 " must be in range [0, %zd)",
167+
"Index out of bounds for weight_scales: index %" PRId64
168+
" must be in range [0, %zd)",
167169
index,
168170
weight_scales.size(0));
169171

kernels/quantized/test/op_embedding_test.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -384,7 +384,8 @@ TEST(OpQuantizedEmbeddingTest, TestOutOfBoundsIndex) {
384384

385385
// Create a weight tensor with 3 rows
386386
TensorFactory<ScalarType::Byte> tfo;
387-
Tensor qweight = tfo.make({3, 4}, {8, 10, 12, 14, 10, 12, 12, 14, 8, 9, 10, 12});
387+
Tensor qweight =
388+
tfo.make({3, 4}, {8, 10, 12, 14, 10, 12, 12, 14, 8, 9, 10, 12});
388389

389390
// Create weight_scales with the same number of rows
390391
Tensor weight_scales = tf.make({3, 1}, {0.5, 1.0, 1.5});

0 commit comments

Comments
 (0)