From b37e81f573d41138ded156b1a90d1ecea916d218 Mon Sep 17 00:00:00 2001 From: fengjiayi Date: Wed, 1 Nov 2017 15:16:59 -0700 Subject: [PATCH 1/2] Fix bug --- python/paddle/v2/framework/layers.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/python/paddle/v2/framework/layers.py b/python/paddle/v2/framework/layers.py index 86a2c7bf08b09..5295761638778 100644 --- a/python/paddle/v2/framework/layers.py +++ b/python/paddle/v2/framework/layers.py @@ -357,7 +357,7 @@ def sequence_pool(input, pool_type, **kwargs): raise ValueError("Unknown pool_type: '%s'. It can only be %s.", str(pool_type), " ".join(ENUM_POOL_TYPE)) - helper = LayerHelper('sequence_pool', **kwargs) + helper = LayerHelper('sequence_pool', **locals()) dtype = helper.input_dtype() pool_out = helper.create_tmp_variable(dtype) From c1babf5948499d324fe69cd831962cfaec2f072f Mon Sep 17 00:00:00 2001 From: fengjiayi Date: Wed, 1 Nov 2017 15:22:32 -0700 Subject: [PATCH 2/2] update --- python/paddle/v2/framework/layers.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/python/paddle/v2/framework/layers.py b/python/paddle/v2/framework/layers.py index 5295761638778..cc75434aa080a 100644 --- a/python/paddle/v2/framework/layers.py +++ b/python/paddle/v2/framework/layers.py @@ -357,7 +357,7 @@ def sequence_pool(input, pool_type, **kwargs): raise ValueError("Unknown pool_type: '%s'. It can only be %s.", str(pool_type), " ".join(ENUM_POOL_TYPE)) - helper = LayerHelper('sequence_pool', **locals()) + helper = LayerHelper('sequence_pool', input=input, **kwargs) dtype = helper.input_dtype() pool_out = helper.create_tmp_variable(dtype)