Skip to content

Commit 14cc156

Browse files
luitjensdanpovey
authored andcommitted
[src] Fix build of online feature extraction with older CUDA version (#3415)
1 parent 00963e2 commit 14cc156

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/cudafeat/online-ivector-feature-cuda.cc

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -243,6 +243,7 @@ void IvectorExtractorFastCuda::ComputeIvectorFromStats(
243243
// Forming new non-SP matrix for cusolver.
244244
CuMatrix<float> A(quadratic);
245245

246+
#if CUDA_VERSION >= 9010
246247
// This is the cusolver return code. Checking it would require
247248
// synchronization.
248249
// So we do not check it.
@@ -269,7 +270,10 @@ void IvectorExtractorFastCuda::ComputeIvectorFromStats(
269270
A.Data(), A.Stride(), ivector->Data(), ivector_dim_, d_info));
270271

271272
CuDevice::Instantiate().Free(workspace);
272-
273+
#else
274+
KALDI_ERROR << "Online Ivectors in CUDA is not supported by your CUDA version. "
275+
<< "Upgrade to CUDA 9.1 or later";
276+
#endif
273277
// remove prior
274278
CuSubVector<float> ivector0(*ivector, 0, 1);
275279
ivector0.Add(-prior_offset_);

0 commit comments

Comments
 (0)