Set FLAGS_use_gpu in test_DetectionOutput.

gangliao-patch-1
yangyaming 8 years ago
parent 65969dad64
commit b233ed1353

@ -65,9 +65,12 @@ void doOneDetectionOutputTest(MatrixPtr& inputLoc,
dataLayers[2]->getOutputValue()->copyFrom(*inputConf);
// test layer initialize
bool store_FLAGS_use_gpu = FLAGS_use_gpu;
FLAGS_use_gpu = use_gpu;
std::vector<ParameterPtr> parameters;
LayerPtr detectionOutputLayer;
initTestLayer(configt, &layerMap, &parameters, &detectionOutputLayer);
FLAGS_use_gpu = store_FLAGS_use_gpu;
detectionOutputLayer->forward(PASS_GC);
checkMatrixEqual(detectionOutputLayer->getOutputValue(), result);
}

Loading…
Cancel
Save