diff --git a/src/nnet3/nnet-batch-compute.cc b/src/nnet3/nnet-batch-compute.cc index 6db046796be..a4baceb2d7f 100644 --- a/src/nnet3/nnet-batch-compute.cc +++ b/src/nnet3/nnet-batch-compute.cc @@ -135,7 +135,7 @@ NnetBatchComputer::GetHighestPriorityComputation( int32 *minibatch_size_out, std::vector *tasks) { tasks->clear(); - std::unique_lock(mutex_); + std::unique_lock lock(mutex_); MapType::iterator iter = tasks_.begin(), end = tasks_.end(), best_iter = tasks_.end(); double highest_priority = -std::numeric_limits::infinity(); diff --git a/src/nnet3/nnet-compute.h b/src/nnet3/nnet-compute.h index 333ed3168b9..f96195ff146 100644 --- a/src/nnet3/nnet-compute.h +++ b/src/nnet3/nnet-compute.h @@ -119,7 +119,7 @@ class NnetComputer { // Version of GetOutput that calls Swap(), destroying the output stored inside // this object. You should probably not use this if you plan to call - // Backward() on the same NnetComputer object, or it's a recurret + // Backward() on the same NnetComputer object, or it's a recurrent // computation-- it may lead to a crash. void GetOutputDestructive(const std::string &output_name, CuMatrix *output);