diff --git a/paddle/fluid/framework/ir/op_compat_sensible_pass.cc b/paddle/fluid/framework/ir/op_compat_sensible_pass.cc index 496d06cc331ca72d628f34745f4df0ad95c6f48e..cbb12839362f3825fc9dab13f85a0f9adaf101a7 100644 --- a/paddle/fluid/framework/ir/op_compat_sensible_pass.cc +++ b/paddle/fluid/framework/ir/op_compat_sensible_pass.cc @@ -117,7 +117,7 @@ InputOrOutputCompat& InputOrOutputCompat::IsOptional() { bool InputOrOutputCompat::operator()( const std::vector& input) const { - if (input.empty()) return false; + if (input.empty()) return optional_; for (auto& func : conditions_) { if (!func(input)) { return false; diff --git a/paddle/fluid/operators/compat/seqconv.pbtxt b/paddle/fluid/operators/compat/sequence_conv.pbtxt similarity index 54% rename from paddle/fluid/operators/compat/seqconv.pbtxt rename to paddle/fluid/operators/compat/sequence_conv.pbtxt index d05aabcc0aa4099a524d32b106c29c148329f472..c5335a25c557a7ee904cbb805735a63d1465ebd5 100644 --- a/paddle/fluid/operators/compat/seqconv.pbtxt +++ b/paddle/fluid/operators/compat/sequence_conv.pbtxt @@ -12,23 +12,42 @@ def { outputs { name: "Out" } -} -extra { attrs { - name: "paddingTrainable" - type: BOOLEAN - } - attrs { name: "contextLength" type: INT } - attrs { + attrs { name: "contextStart" type: INT } - attrs { + attrs { name: "contextStride" type: INT - } - + } +} +extra { + attrs { + name: "paddingTrainable" + type: BOOLEAN + } + attrs { + name: "op_role" + type: INT + } + attrs { + name: "op_role_var" + type: STRINGS + } + attrs { + name: "op_namescope" + type: STRING + } + attrs { + name: "op_callstack" + type: STRINGS + } + attrs { + name: "op_device" + type: STRING + } }