mirror of
https://github.com/microsoft/mscclpp.git
synced 2026-05-12 17:26:04 +00:00
Provides two integration ways for MSCCL++ DSL. 1. Integrate with customized communication group 2. Integrate with NCCL API Introduce new Python APIs to make it work: ```python mscclpp.compile # compile dsl to json based execution plan mscclpp.ExecutionPlanRegistry.register_plan(plan) # register the compiled plan to executionPlanRegistery mscclpp.ExecutionPlanRegistry.set_selector(selector) # set the selector, the selector will return the best execution plan based on collection, message size, world size.... ``` Fix #556 --------- Co-authored-by: Caio Rocha <caiorocha@microsoft.com> Co-authored-by: Changho Hwang <changhohwang@microsoft.com>
14 lines
380 B
C++
14 lines
380 B
C++
#include <nanobind/nanobind.h>
|
|
namespace nb = nanobind;
|
|
|
|
namespace mscclpp {
|
|
int getDeviceNumaNode(int cudaDev);
|
|
void numaBind(int node);
|
|
}; // namespace mscclpp
|
|
|
|
void register_numa(nb::module_ &m) {
|
|
nb::module_ sub_m = m.def_submodule("numa", "numa functions");
|
|
sub_m.def("get_device_numa_node", &mscclpp::getDeviceNumaNode);
|
|
sub_m.def("numa_bind", &mscclpp::numaBind);
|
|
}
|