提交 6bd3ed92 编写于 作者: D Dang Qingqing

Fix unit test in Python3.5

上级 6f32fdb1
...@@ -46,7 +46,7 @@ from . import transpiler ...@@ -46,7 +46,7 @@ from . import transpiler
from .param_attr import ParamAttr, WeightNormParamAttr from .param_attr import ParamAttr, WeightNormParamAttr
from .data_feeder import DataFeeder from .data_feeder import DataFeeder
from .core import LoDTensor, LoDTensorArray, CPUPlace, CUDAPlace, CUDAPinnedPlace, Scope from .core import LoDTensor, LoDTensorArray, CPUPlace, CUDAPlace, CUDAPinnedPlace, Scope
from .transpiler import DistributeTranspiler, \ from .transpiler import DistributeTranspiler, InferenceTranspiler, \
memory_optimize, release_memory, DistributeTranspilerConfig memory_optimize, release_memory, DistributeTranspilerConfig
from .lod_tensor import create_lod_tensor, create_random_int_lodtensor from .lod_tensor import create_lod_tensor, create_random_int_lodtensor
from . import clip from . import clip
......
...@@ -210,7 +210,7 @@ class TestQuantizeTranspiler(unittest.TestCase): ...@@ -210,7 +210,7 @@ class TestQuantizeTranspiler(unittest.TestCase):
with fluid.program_guard(main): with fluid.program_guard(main):
for _ in range(iter): for _ in range(iter):
data = train_reader().next() data = next(train_reader())
loss_v = exe.run(program=main, loss_v = exe.run(program=main,
feed=feeder.feed(data), feed=feeder.feed(data),
fetch_list=[loss]) fetch_list=[loss])
......
...@@ -15,6 +15,7 @@ ...@@ -15,6 +15,7 @@
from __future__ import print_function from __future__ import print_function
from .distribute_transpiler import DistributeTranspiler, DistributeTranspilerConfig from .distribute_transpiler import DistributeTranspiler, DistributeTranspilerConfig
from .inference_transpiler import InferenceTranspiler
from .memory_optimization_transpiler import memory_optimize, release_memory from .memory_optimization_transpiler import memory_optimize, release_memory
from .ps_dispatcher import HashName, RoundRobin from .ps_dispatcher import HashName, RoundRobin
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册