Skip to content

Commit 81d1b54

Browse files
authored
Reverted removing optional
1 parent adb373c commit 81d1b54

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

paddle/fluid/framework/ir/mkldnn/conv_activation_mkldnn_fuse_pass.cc

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -228,12 +228,14 @@ Conv2DHardSigmoidFusePass::Conv2DHardSigmoidFusePass() {
228228
.AddOutput("Out")
229229
.IsTensor()
230230
.End()
231-
// default=0.2
231+
// optional, default=0.2
232232
.AddAttr("slope")
233+
.IsOptional()
233234
.IsType<float>()
234235
.End()
235-
// default=0.5
236+
// optional, default=0.5
236237
.AddAttr("offset")
238+
.IsOptional()
237239
.IsType<float>()
238240
.End();
239241
}

0 commit comments

Comments
 (0)