Skip to content

Commit 06d61e1

Browse files
authored
fix some error find by cpplint (#202)
1 parent 6c50ec2 commit 06d61e1

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

nlp_toolkit/backends/neural_engine/executor/include/operator.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
#include <algorithm>
1919
#include <string>
2020
#include <vector>
21-
#include <mutex>
21+
#include <mutex> //NOLINT
2222

2323
#include "common.hpp"
2424
#include "operator_registry.hpp"

nlp_toolkit/backends/neural_engine/test/gtest/SparseLib/test_spmm_amx_bf16_x16_kernel.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -304,7 +304,7 @@ std::string test_suffix(testing::TestParamInfo<test_params_t> tpi) {
304304
params.push_back(std::to_string(tensor_desc[ssd::SRC].shape()[0]));
305305
params.push_back(std::to_string(tensor_desc[ssd::SRC].shape()[1]));
306306
params.push_back(std::to_string(tensor_desc[ssd::WEI].shape()[0]));
307-
params.push_back(std::to_string(tensor_desc[ssd::SRC].shape()[2])); // micro bs
307+
params.push_back(std::to_string(tensor_desc[ssd::SRC].shape()[2])); // micro bs
308308
params.push_back(attrs_map["micro_oc"]);
309309
params.push_back(std::to_string(tensor_desc[ssd::DST].dtype() == dt::bf16));
310310
if (!attrs_map["postop_list"].empty()) params.push_back(attrs_map["postop_list"]);

nlp_toolkit/backends/neural_engine/test/gtest/test_sparse_inner_product.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@ Tensor* make_int32_bias_obj(const TensorConfig* bias_tensor_config, const float*
139139

140140
const float zp = *reinterpret_cast<const float*>(src_min->data());
141141
const float* weight_data = reinterpret_cast<const float*>(weight_fp32->data());
142-
//#pragma omp parallel for
142+
// #pragma omp parallel for
143143
for (int y = 0; y < weight_fp32->shape()[1]; y++) {
144144
float compensation = 0;
145145
for (int x = 0; x < weight_fp32->shape()[0]; x++) compensation += weight_data[x * weight_fp32->shape()[1] + y];
@@ -149,7 +149,7 @@ Tensor* make_int32_bias_obj(const TensorConfig* bias_tensor_config, const float*
149149
}
150150

151151
Tensor* get_fp32_dst(const TensorConfig* dst_tensor_config, vector<Tensor*> inputs) {
152-
using namespace dnnl;
152+
// using namespace dnnl;
153153
Tensor* dst_tensor = new Tensor(*dst_tensor_config);
154154
dst_tensor->add_tensor_life(1);
155155
engine engine(engine::kind::cpu, 0);
@@ -246,7 +246,7 @@ vector<Tensor*> make_transposed_int8_tensor_obj(vector<const TensorConfig*> tens
246246
}
247247
delete[] transposed_data;
248248
return tensors;
249-
};
249+
}
250250

251251
OpArgs GenenrateCopies(vector<TensorConfig*> old_configs, vector<Tensor*> old_tensors, Tensor* old_dst,
252252
std::map<std::string, std::string> attr_map) {

0 commit comments

Comments
 (0)