Add Benchmark.setIsCPUOnly API

This commit is contained in:
Oleksandr Pavlyk
2025-07-21 10:56:31 -05:00
parent 7f9d672cec
commit aa2b4d9960

View File

@@ -286,6 +286,13 @@ PYBIND11_MODULE(_nvbench, m)
return std::ref(self);
},
py::return_value_policy::reference);
py_benchmark_cls.def(
"setIsCPUOnly",
[](nvbench::benchmark_base &self, bool is_cpu_only) {
self.set_is_cpu_only(is_cpu_only);
return std::ref(self);
},
py::return_value_policy::reference);
// == STEP 5
// Define PyState class