mirror of
https://github.com/nomic-ai/kompute.git
synced 2026-05-11 08:59:59 +00:00
Removed spdlog references
This commit is contained in:
@@ -11,6 +11,8 @@ namespace py = pybind11;
|
||||
py::object kp_debug, kp_info, kp_warning, kp_error;
|
||||
|
||||
PYBIND11_MODULE(kp, m) {
|
||||
|
||||
// The logging modules are used in the Kompute.hpp file
|
||||
py::module_ logging = py::module_::import("logging");
|
||||
py::object kp_logger = logging.attr("getLogger")("kp");
|
||||
kp_debug = kp_logger.attr("debug");
|
||||
@@ -21,19 +23,6 @@ PYBIND11_MODULE(kp, m) {
|
||||
|
||||
py::module_ np = py::module_::import("numpy");
|
||||
|
||||
#if KOMPUTE_ENABLE_SPDLOG
|
||||
spdlog::set_level(
|
||||
static_cast<spdlog::level::level_enum>(SPDLOG_ACTIVE_LEVEL));
|
||||
#endif
|
||||
|
||||
m.def("log_level", [](uint8_t logLevel) {
|
||||
#if KOMPUTE_ENABLE_SPDLOG
|
||||
spdlog::set_level(
|
||||
static_cast<spdlog::level::level_enum>(logLevel));
|
||||
#else
|
||||
SPDLOG_WARN("SPDLOG not enabled so log level config function not supported");
|
||||
#endif
|
||||
});
|
||||
|
||||
py::enum_<kp::Tensor::TensorTypes>(m, "TensorTypes", DOC(kp, Tensor, TensorTypes))
|
||||
.value("device", kp::Tensor::TensorTypes::eDevice, "Tensor holding data in GPU memory.")
|
||||
@@ -42,9 +31,6 @@ PYBIND11_MODULE(kp, m) {
|
||||
.export_values();
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
py::class_<kp::Tensor, std::shared_ptr<kp::Tensor>>(m, "Tensor", DOC(kp, Tensor))
|
||||
.def(py::init(
|
||||
[np](const py::array_t<float> data, kp::Tensor::TensorTypes tensor_type) {
|
||||
@@ -101,9 +87,6 @@ PYBIND11_MODULE(kp, m) {
|
||||
.def("map_data_into_host", &kp::Tensor::mapDataIntoHostMemory, "Maps data from GPU memory into tensor local data.");
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
py::class_<kp::Sequence, std::shared_ptr<kp::Sequence>>(m, "Sequence")
|
||||
.def("init", &kp::Sequence::init, "Initialises Vulkan resources within sequence using provided device.")
|
||||
|
||||
@@ -164,9 +147,6 @@ PYBIND11_MODULE(kp, m) {
|
||||
"Records operation to run left right out operation with custom shader");
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
py::class_<kp::Manager>(m, "Manager")
|
||||
.def(py::init(), "Default initializer uses device 0 and first compute compatible GPU queueFamily")
|
||||
.def(py::init(
|
||||
|
||||
Reference in New Issue
Block a user