Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix DataCollatorForSeq2Seq when labels are supplied as Numpy array instead of list #13582

Merged
merged 2 commits into from
Sep 16, 2021

Conversation

Rocketknight1
Copy link
Member

Found a bug in my data collator code - the Seq2Seq collator doesn't work unless labels are supplied as a list, and it fails if they're passed as an array.

Copy link
Collaborator

@sgugger sgugger left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks for fixing!

Copy link
Member

@LysandreJik LysandreJik left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for working on it @Rocketknight1

@Rocketknight1 Rocketknight1 merged commit 5c59371 into master Sep 16, 2021
@Rocketknight1 Rocketknight1 deleted the seq2seq_collator_numpy_fix branch September 16, 2021 14:35
Albertobegue pushed a commit to Albertobegue/transformers that referenced this pull request Jan 13, 2022
…stead of list (huggingface#13582)

* Fix issue when labels are supplied as Numpy array instead of list

* Fix issue when labels are supplied as Numpy array instead of list
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants