Skip to content

Commit

Permalink
update modeling_seq2seq.py
Browse files Browse the repository at this point in the history
  • Loading branch information
ARK authored and ARK committed Aug 21, 2023
1 parent b500f22 commit 7d27fdb
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions optimum/onnxruntime/modeling_seq2seq.py
Original file line number Diff line number Diff line change
Expand Up @@ -1486,8 +1486,8 @@ def forward(
flattened_patches=flattened_patches,
attention_mask=attention_mask,
)
# work around for Unexpected input data type (tensor(float)) for attention_mask
# Need to be looked into

#decoder requires torch.LongTensor for attention_mask
attention_mask = attention_mask.to(torch.int64)
# Decode

Expand Down

0 comments on commit 7d27fdb

Please sign in to comment.