提交 882a9327 编写于 作者: S sneaxiy

Revert "commit"

This reverts commit e0f883e6.
上级 090cd0ab
......@@ -156,23 +156,15 @@ def train(avg_loss, infer_prog, optimizer, train_reader, test_reader, batch_acc,
start_time = time.time()
num_samples = 0
if arg.profile and pass_id == 0 and batch_id == 5:
profiler.start_profiler("All")
elif args.profile and pass_id == 0 and batch_id == 10:
profiler.stop_profiler("total", "/tmp/profile")
if args.use_reader_op:
try:
loss = exe.run(train_prog,
fetch_list=[avg_loss],
use_program_cache=True)
loss = exe.run(train_prog, fetch_list=[avg_loss])
except fluid.core.EnforceNotMet as ex:
break
else:
loss = exe.run(train_prog,
feed=feeder.feed(data),
fetch_list=[avg_loss],
use_program_cache=True)
fetch_list=[avg_loss])
iters += 1
batch_id += 1
# FIXME(wuyi): For use_reader_op, if the current
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册