46 comm->AllReduce(toReduce, oper);
58 py::class_<Comm, std::shared_ptr<Comm>, boost::noncopyable>(
"Comm",
60 .def(
"GetSize", &Comm::GetSize)
61 .def(
"GetRank", &Comm::GetRank)
62 .def(
"GetType", &Comm::GetType,
63 py::return_value_policy<py::copy_const_reference>())
64 .def(
"AllReduce", &AllReduce<double>)
65 .def(
"AllReduce", &AllReduce<int>)
66 .def(
"AllReduce", &AllReduce<long>)
#define NEKPY_WRAP_ENUM(ENUMNAME, MAPNAME)
void export_Comm()
Export for Comm communicator.
T AllReduce(CommSharedPtr &comm, T toReduce, ReduceOperator oper)
const char *const ReduceOperatorMap[]
ReduceOperator
Type of operation to perform in AllReduce.
std::shared_ptr< Comm > CommSharedPtr
Pointer to a Communicator object.