Skip to content

Commit

Permalink
Fix quantization test for XLNet (#1699)
Browse files Browse the repository at this point in the history
  • Loading branch information
james77777778 authored Jul 19, 2024
1 parent b0c21b3 commit f5c1fc1
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 1 deletion.
1 change: 0 additions & 1 deletion keras_nlp/src/models/xlnet/xlnet_backbone_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,6 @@ def test_backbone_basics(self):
init_kwargs=self.init_kwargs,
input_data=self.input_data,
expected_output_shape=(2, 5, 2),
run_quantization_check=False, # TODO(hongyu): set to `True`
)

@pytest.mark.large
Expand Down
1 change: 1 addition & 0 deletions keras_nlp/src/models/xlnet/xlnet_encoder.py
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,7 @@ def build(self, input_shape):
dtype=self.dtype_policy,
name="rel_attn",
)
self.relative_attention.build(input_shape)

self.layer_norm = keras.layers.LayerNormalization(
epsilon=self.layer_norm_epsilon,
Expand Down

0 comments on commit f5c1fc1

Please sign in to comment.