Skip to content

Commit 9d4fcce

Browse files
committed
Enable compilation of kaldi pybind without GPU (fix #3825).
1 parent 4807173 commit 9d4fcce

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/pybind/dlpack/dlpack_pybind.cc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -296,7 +296,7 @@ DLPackCuSubVector<float>* CuSubVectorFromDLPack(py::capsule* capsule) {
296296
tensor->shape[0], managed_tensor);
297297
#else
298298
KALDI_ERR << "Kaldi is not compiled with GPU!";
299-
return py::none();
299+
return nullptr;
300300
#endif
301301
}
302302

@@ -312,7 +312,7 @@ DLPackCuSubMatrix<float>* CuSubMatrixFromDLPack(py::capsule* capsule) {
312312
tensor->strides[0], managed_tensor);
313313
#else
314314
KALDI_ERR << "Kaldi is not compiled with GPU!";
315-
return py::none();
315+
return nullptr;
316316
#endif
317317
}
318318

0 commit comments

Comments
 (0)