Skip to content

Commit 184a610

Browse files
authoredMay 14, 2024
Update optimum/exporters/openvino/model_patcher.py
1 parent bf2ae08 commit 184a610

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed
 

‎optimum/exporters/openvino/model_patcher.py

+3-3
Original file line numberDiff line numberDiff line change
@@ -341,9 +341,9 @@ def _llama_gemma_update_causal_mask(self, attention_mask, input_tensor, cache_po
341341
offset = 0
342342
mask_shape = attention_mask.shape
343343
mask_slice = (attention_mask.eq(0.0)).to(dtype=dtype) * min_dtype
344-
causal_mask[: mask_shape[0], : mask_shape[1], offset : mask_shape[2] + offset, : mask_shape[3]] = (
345-
mask_slice
346-
)
344+
causal_mask[
345+
: mask_shape[0], : mask_shape[1], offset : mask_shape[2] + offset, : mask_shape[3]
346+
] = mask_slice
347347

348348
if (
349349
self.config._attn_implementation == "sdpa"

0 commit comments

Comments
 (0)