Skip to content

Commit

Permalink
[Paddle Inference]Disable skip layernorm half (#45047)
Browse files Browse the repository at this point in the history
* disable_skip_layernorm_fp16
  • Loading branch information
Wangzheee committed Aug 10, 2022
1 parent 3f49817 commit 4805da5
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions paddle/fluid/inference/tensorrt/convert/skip_layernorm.cc
Original file line number Diff line number Diff line change
Expand Up @@ -163,8 +163,10 @@ class SkipLayerNormOpConverter : public OpConverter {
auto scale_weight = GetFp32Weight("Scale").get();

float eps = PADDLE_GET_CONST(float, op_desc.GetAttr("epsilon"));
bool with_fp16 =
engine_->WithFp16() && !engine_->disable_trt_plugin_fp16();
// bool with_fp16 =
// engine_->WithFp16() && !engine_->disable_trt_plugin_fp16();
bool with_fp16 = false;

plugin::SkipLayerNormPluginDynamic* plugin =
new plugin::SkipLayerNormPluginDynamic(
static_cast<const float*>(bias_weight.values),
Expand Down

0 comments on commit 4805da5

Please sign in to comment.