Code Example - Code Example - 2026.1 English

Vitis Libraries

Release Date
2026-06-23
Version
2026.1 English
#include <adf.h>
#include "svd_graph.hpp"

using namespace adf;
namespace svd_example {

#define DATA_TYPE_SVD float
#define DIM_ROWS_SVD 8
#define DIM_COLS_SVD 4
#define PASSES_SVD 4
#define CASC_LEN_SVD 1

class test_svd : public adf::graph {
   public:
    port<input> in;
    port<output> outU;
    port<output> outS;
    port<output> outV;
    xf::solver::aie::svd::svd_graph<DATA_TYPE_SVD, DIM_ROWS_SVD, DIM_COLS_SVD, PASSES_SVD, CASC_LEN_SVD> svdGraph;

    test_svd() {
        connect<>(in, svdGraph.in[0]);
        connect<>(svdGraph.outU[0], outU);
        connect<>(svdGraph.outS[0], outS);
        connect<>(svdGraph.outV[0], outV);
    };
};
};