Skip to content

padding_idx is tensor, not integer, for most models #293

@skinnider

Description

@skinnider

Noticed while reviewing PR #289 that Vishu’s Hyena implementation passes in the padding_idx as an integer to nn.Embedding, but the other models wrap it in a tensor. It turns out the former is correct per the Pytorch API: https://docs.pytorch.org/docs/stable/generated/torch.nn.Embedding.html. Minor fix, but one that should be made for consistency.

Metadata

Metadata

Labels

No labels
No labels

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions