Skip to content

Commit ccb4e87

Browse files
committed
phy: fix preoding config test
1 parent 36ff990 commit ccb4e87

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

include/srsran/ran/precoding/precoding_weight_matrix.h

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
#include "srsran/ran/precoding/precoding_constants.h"
1515
#include "srsran/srsvec/copy.h"
1616
#include "srsran/srsvec/sc_prod.h"
17+
#include "srsran/srsvec/zero.h"
1718

1819
namespace srsran {
1920

@@ -28,6 +29,9 @@ class precoding_weight_matrix
2829
precoding_weight_matrix() = default;
2930

3031
/// \brief Constructs a weight matrix with the desired number of layers and ports.
32+
///
33+
/// The coefficients are set to zero.
34+
///
3135
/// \param[in] nof_layers Number of layers.
3236
/// \param[in] nof_ports Number of ports.
3337
/// \remark An assertion is triggered if the number of layers exceeds \ref precoding_constants::MAX_NOF_LAYERS.
@@ -42,6 +46,9 @@ class precoding_weight_matrix
4246
"The number of ports (i.e., {}) exceeds the maximum (i.e., {}).",
4347
nof_ports,
4448
precoding_constants::MAX_NOF_PORTS);
49+
50+
// Zero all data.
51+
srsvec::zero(data.get_data());
4552
}
4653

4754
/// \brief Constructs a weight matrix with the desired number of layers and ports.

0 commit comments

Comments
 (0)