SSCMA-Micro CPP SDK  v2.0.0
SSCMA-Micro is a cross-platform machine learning inference framework designed for embedded devices.
ma_anchors.h
Go to the documentation of this file.
1 #ifndef _MA_UTILS_ANCHORS_H_
2 #define _MA_UTILS_ANCHORS_H_
3 
4 #include <cstddef>
5 #include <cstdint>
6 #include <vector>
7 
8 #include "../ma_types.h"
9 
10 namespace ma::utils {
11 
12 std::vector<ma_anchor_stride_t> generateAnchorStrides(size_t input_size, std::vector<size_t> strides = {8, 16, 32});
13 
14 std::vector<std::vector<ma_pt2f_t>> generateAnchorMatrix(const std::vector<ma_anchor_stride_t>& anchor_strides,
15  float shift_right = 1.f,
16  float shift_down = 1.f);
17 
18 } // namespace ma::utils
19 
20 #endif
Definition: ma_anchors.cpp:3
std::vector< std::vector< ma_pt2f_t > > generateAnchorMatrix(const std::vector< ma_anchor_stride_t > &anchor_strides, float shift_right, float shift_down)
Definition: ma_anchors.cpp:20
std::vector< ma_anchor_stride_t > generateAnchorStrides(size_t input_size, std::vector< size_t > strides)
Definition: ma_anchors.cpp:5