提交 968ee0c0 编写于 作者: L liuqi

Remove static keyword in header files.

上级 c63ba922
......@@ -19,7 +19,7 @@
namespace mace {
namespace kernels {
static constexpr int kCostPerGroup = 1024;
constexpr int kCostPerGroup = 1024;
template <DeviceType D, typename T>
struct AddNFunctor {
......
......@@ -15,7 +15,7 @@
namespace mace {
namespace kernels {
static inline std::vector<float> WHCenters(const std::vector<float> &anchor) {
inline std::vector<float> WHCenters(const std::vector<float> &anchor) {
// width, height, width_center, height_center
std::vector<float> window(4);
window[0] = anchor[2] - anchor[0] + 1;
......@@ -25,7 +25,7 @@ static inline std::vector<float> WHCenters(const std::vector<float> &anchor) {
return window;
}
static inline std::vector<std::vector<float>> GenerateAnchors(
inline std::vector<std::vector<float>> GenerateAnchors(
const std::vector<int> &scales,
const std::vector<float> &ratios,
const int base_size) {
......@@ -65,7 +65,7 @@ static inline std::vector<std::vector<float>> GenerateAnchors(
return anchors;
}
static inline std::vector<int> nms(const float *bboxes_ptr,
inline std::vector<int> nms(const float *bboxes_ptr,
const index_t num_bboxes,
const float thresh,
const int post_nms_top_n) {
......
......@@ -23,7 +23,7 @@ struct CachedInterpolation {
float lerp;
};
static inline float CalculateResizeScale(index_t in_size,
inline float CalculateResizeScale(index_t in_size,
index_t out_size,
bool align_corners) {
return (align_corners && out_size > 1)
......@@ -31,7 +31,7 @@ static inline float CalculateResizeScale(index_t in_size,
: in_size / static_cast<float>(out_size);
}
static inline void ComputeInterpolationWeights(
inline void ComputeInterpolationWeights(
const index_t out_size,
const index_t in_size,
const float scale,
......@@ -46,7 +46,7 @@ static inline void ComputeInterpolationWeights(
}
}
static inline float ComputeLerp(const float top_left,
inline float ComputeLerp(const float top_left,
const float top_right,
const float bottom_left,
const float bottom_right,
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册