Template Function Pennylane::LightningGPU::MPI::scatterCSRMatrix

Function Documentation

template<class Precision, class index_type>
auto Pennylane::LightningGPU::MPI::scatterCSRMatrix(MPIManager &mpi_manager, std::vector<CSRMatrix<Precision, index_type>> &matrix, std::size_t local_num_rows, std::size_t root) -> CSRMatrix<Precision, index_type>

Scatter a CSR (Compressed Sparse Row) format matrix.

Template Parameters
  • Precision – Floating-point precision type.

  • index_type – Integer type used as indices of the sparse matrix.

Parameters
  • mpi_managerMPIManager object.

  • matrix – CSR (Compressed Sparse Row) format matrix vector.

  • local_num_rows – Number of rows of local CSR matrix.

  • root – Root rank of the scatter operation.