Merge remote-tracking branch 'origin/develop-nr' into shortBlockCoding
Conflicts: cmake_targets/CMakeLists.txt cmake_targets/autotests/test_case_list.xml cmake_targets/build_oai openair1/PHY/CODING/TESTBENCH/polartest.c openair1/PHY/CODING/nrPolar_tools/nr_polar_decoder.c openair1/PHY/CODING/nrPolar_tools/nr_polar_decoding_tools.c openair1/PHY/CODING/nrPolar_tools/nr_polar_defs.h openair1/PHY/CODING/nrPolar_tools/nr_polar_encoder.c openair1/PHY/CODING/nr_polar_init.c openair1/SCHED_NR_UE/phy_procedures_nr_ue.c openair1/SCHED_NR_UE/pucch_uci_ue_nr.c openair1/SIMULATION/NR_PHY/dlschsim.c openair1/SIMULATION/NR_PHY/dlsim.c openair2/LAYER2/NR_MAC_gNB/gNB_scheduler.c
This commit is contained in:
@@ -48,8 +48,8 @@ uint16_t decodeSmallBlock(int8_t *in, uint8_t len){
|
||||
int16_t Rhat[NR_SMALL_BLOCK_CODED_BITS] = {0}, Rhatabs[NR_SMALL_BLOCK_CODED_BITS] = {0};
|
||||
uint16_t maxVal;
|
||||
uint8_t maxInd = 0;
|
||||
|
||||
for (int j = 0; j < NR_SMALL_BLOCK_CODED_BITS; ++j)
|
||||
int jmax = (1<<(len-1));
|
||||
for (int j = 0; j < jmax; ++j)
|
||||
for (int k = 0; k < NR_SMALL_BLOCK_CODED_BITS; ++k)
|
||||
Rhat[j] += in[k] * hadamard32InterleavedTransposed[j][k];
|
||||
|
||||
@@ -67,7 +67,7 @@ uint16_t decodeSmallBlock(int8_t *in, uint8_t len){
|
||||
}
|
||||
#endif
|
||||
maxVal = Rhatabs[0];
|
||||
for (int k = 1; k < NR_SMALL_BLOCK_CODED_BITS; ++k){
|
||||
for (int k = 1; k < jmax; ++k){
|
||||
if (Rhatabs[k] > maxVal){
|
||||
maxVal = Rhatabs[k];
|
||||
maxInd = k;
|
||||
@@ -77,7 +77,7 @@ uint16_t decodeSmallBlock(int8_t *in, uint8_t len){
|
||||
out = properOrderedBasis[maxInd] | ( (Rhat[maxInd] > 0) ? (uint16_t)0 : (uint16_t)1 );
|
||||
|
||||
#ifdef DEBUG_DECODESMALLBLOCK
|
||||
for (int k = 0; k < NR_SMALL_BLOCK_CODED_BITS; ++k)
|
||||
for (int k = 0; k < jmax; ++k)
|
||||
printf("[decodeSmallBlock]Rhat[%d]=%d %d %d %d\n",k, Rhat[k], maxVal, maxInd, ((uint32_t)out>>k)&1);
|
||||
printf("[decodeSmallBlock]0x%x 0x%x\n", out, properOrderedBasis[maxInd]);
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user