Skip to content

misleading variable name in transformer tutorial #1944

Open
@gitty-up

Description

@gitty-up

https://github.com/pytorch/tutorials/blob/master/beginner_source/transformer_tutorial.py#L300

batch_size is a bad variable name, because it is not the dimension usually referred to as the batch size.. Instead, it is the sequence length associated with a particular batch. I suggest using batch_seq_len for clarity.

cc @suraj813

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions