зеркало из https://github.com/mozilla/kaldi.git
trunk: Fixing bug in cu-device.cc that stopped GPU from working if you got it after retry.
git-svn-id: https://svn.code.sf.net/p/kaldi/code/trunk@3227 5e6a8d80-dfce-4ca6-a32a-6e07a63d50c8
This commit is contained in:
Родитель
7e2bc96dbb
Коммит
38c0e03b4b
|
@ -103,7 +103,7 @@ void CuDevice::SelectGpuId(std::string use_gpu) {
|
|||
KALDI_WARN << "Will try again to get a GPU after " << sec_sleep
|
||||
<< " seconds.";
|
||||
sleep(sec_sleep);
|
||||
//
|
||||
cudaGetLastError(); // reset the error state
|
||||
e = cudaThreadSynchronize(); //<< 2nd trial to get CUDA context.
|
||||
if (e != cudaSuccess) {
|
||||
if (use_gpu == "yes") {
|
||||
|
|
|
@ -21,8 +21,6 @@
|
|||
#ifndef KALDI_FEAT_FEATURE_FUNCTIONS_H_
|
||||
#define KALDI_FEAT_FEATURE_FUNCTIONS_H_
|
||||
|
||||
#include <cassert>
|
||||
#include <cstdlib>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче