From 94a13bc61c298a5e5c3f3085f1a480517d50ca33 Mon Sep 17 00:00:00 2001 From: dong zhihong Date: Wed, 17 May 2017 17:24:51 +0800 Subject: [PATCH] remove buffered function call" --- ltr/lambdaRank.py | 3 +-- ltr/ranknet.py | 4 +--- 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/ltr/lambdaRank.py b/ltr/lambdaRank.py index b6f97522..1de24987 100644 --- a/ltr/lambdaRank.py +++ b/ltr/lambdaRank.py @@ -37,8 +37,7 @@ def train_lambdaRank(num_passes): paddle.dataset.mq2007.test, format="listwise") train_reader = paddle.batch( paddle.reader.shuffle(fill_default_train, buf_size=100), batch_size=32) - test_reader = paddle.batch( - paddle.reader.buffered(fill_default_test, size=100), batch_size=32) + test_reader = paddle.batch(fill_default_test, batch_size=32) # mq2007 input_dim = 46, dense format input_dim = 46 diff --git a/ltr/ranknet.py b/ltr/ranknet.py index e849d128..ca3b6c70 100644 --- a/ltr/ranknet.py +++ b/ltr/ranknet.py @@ -54,9 +54,7 @@ def train_ranknet(num_passes): train_reader = paddle.batch( paddle.reader.shuffle(paddle.dataset.mq2007.train, buf_size=100), batch_size=100) - test_reader = paddle.batch( - paddle.reader.buffered(paddle.dataset.mq2007.test, size=100), - batch_size=100) + test_reader = paddle.batch(paddle.dataset.mq2007.test, batch_size=100) # mq2007 feature_dim = 46, dense format # fc hidden_dim = 128 -- GitLab