MCPcopy Create free account
hub / github.com/Xilinx/CHaiDNN / LoadMeanBuff

Function LoadMeanBuff

design/conv/src/xi_convolution.hpp:5167–5190  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

5165}
5166
5167void LoadMeanBuff(input_struct input_desc,
5168 gmem_inputtype_layer1 *gmem_mean_fa0,
5169 short mean_buff[2][1024],
5170 short variance_buff[2][1024],
5171 short beta_buff[2][1024])
5172{
5173#pragma HLS INLINE OFF
5174#pragma HLS ARRAY_PARTITION variable=mean_buff complete dim=1
5175#pragma HLS ARRAY_PARTITION variable=variance_buff complete dim=1
5176#pragma HLS ARRAY_PARTITION variable=beta_buff complete dim=1
5177#pragma HLS resource variable=mean_buff core=RAM_T2P_BRAM
5178#pragma HLS resource variable=variance_buff core=RAM_T2P_BRAM
5179#pragma HLS resource variable=beta_buff core=RAM_T2P_BRAM
5180
5181 int offset = 0;
5182 ap_uint<16> loop_cnt = input_desc.planes / 4;
5183 for (ap_uint<4> cnt = 0; cnt < 3; cnt++)
5184 {
5185 ReadMean(input_desc, gmem_mean_fa0 + offset, mean_buff, variance_buff,beta_buff, loop_cnt, cnt);
5186
5187 offset = offset + input_desc.planes / 4;
5188 }
5189
5190}
5191
5192void WriteNormData(conv_struct conv_desc, ap_uint<16> layerx_loop_cnt_fg0,
5193 input_struct input_desc,

Callers 1

LoadIStagingBuff_fgFunction · 0.85

Calls 1

ReadMeanFunction · 0.85

Tested by

no test coverage detected