@@ -180,7 +180,7 @@ def train(avg_loss, infer_prog, optimizer, train_reader, test_reader, batch_acc,
180
180
print_train_time (start_time , time .time (), num_samples )
181
181
print ("Pass: %d, Loss: %f" % (pass_id , np .mean (train_losses ))),
182
182
# evaluation
183
- if not args .no_test and batch_acc :
183
+ if not args .no_test and batch_acc and not args . use_reader_op :
184
184
pass_test_acc = test (exe , infer_prog , test_reader , feeder ,
185
185
batch_acc )
186
186
print (", Test Accuracy: %f" % pass_test_acc )
@@ -277,11 +277,12 @@ def train_parallel(avg_loss, infer_prog, optimizer, train_reader, test_reader,
277
277
batch_id += 1
278
278
279
279
print_train_time (start_time , time .time (), num_samples )
280
- if not args .no_test and batch_acc :
280
+ if not args .no_test and batch_acc and not args .use_reader_op :
281
+ # we have not implement record io for test
282
+ # skip test when use args.use_reader_op
281
283
test_acc = test (startup_exe , infer_prog , test_reader , feeder ,
282
284
batch_acc )
283
285
print ("Pass: %d, Test Accuracy: %f\n " % (pass_id , test_acc ))
284
- exit (0 )
285
286
286
287
287
288
def print_arguments (args ):
0 commit comments