onnxruntime/onnxruntime/python/tools/kernel_explorer/kernel_explorer.cpp
zhangyaobit f6d2b629a0
Add kernel explorer (#11779)
* Add kernel explorer, a tool to help develop, test, profile, and tune GPU kernels.

* clean up with some formatting issues

* rename MACRO

* macro renaming

* improve cmake code

* fix python lint errors

* fix python lint errors

* fix python lint errors

* delete white space suggested by lint
2022-06-13 20:11:25 -07:00

16 lines
447 B
C++

// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
#include <pybind11/pybind11.h>
#include <pybind11/numpy.h>
#include "device_array.h"
#include "kernels/vector_add.h"
namespace py = pybind11;
PYBIND11_MODULE(kernel_explorer, m) {
py::class_<DeviceArray>(m, "DeviceArray")
.def(py::init<py::array>())
.def("UpdateHostNumpyArray", &DeviceArray::UpdateHostNumpyArray);
InitVectorAdd(m);
}