We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 3f6d407 commit 6ba3138Copy full SHA for 6ba3138
python/llm/src/ipex_llm/transformers/models/bert.py
@@ -119,7 +119,7 @@ def encoder_forward(
119
output_hidden_states: Optional[bool] = False,
120
return_dict: Optional[bool] = True,
121
):
122
- if attention_mask and not attention_mask.any():
+ if attention_mask is not None and not attention_mask.any():
123
attention_mask = None
124
return BertEncoder.forward(
125
self=self,
0 commit comments