Skip to content

Stop prediction when EOS is reached #5

Open

Description

@surenreddy

Hi Dongjun,
In line 38, of the Graph class, the following loop continues until max sequence length is decoded.
for i in range(2, Config.data.max_seq_length):

Is it possible to break the loop when EOS(end of the sequence) is reached for the batch?

Thank you,
Surendra

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions