Skip to content
This repository was archived by the owner on Feb 7, 2025. It is now read-only.
This repository was archived by the owner on Feb 7, 2025. It is now read-only.

VQVAETransformerInferer not compatible with a maximum sequence length #281

@marksgraham

Description

@marksgraham

If we set max_seq_length to a value smaller than the full sequence length of the encoded image, this error is thrown upon training:

AssertionError: you are passing in a sequence length of 12585 but your absolute positional embedding has a max sequence length of 1000

Fixing this during training should be straightforward, if max_seq_length is smaller than the total sequene length we should train on a random section of the sequence of length max_seq_length.

I guess that we need to make get_likelihood more like the sampling function; so it loops and predicts the logits for the next token using a previous context of length max_seq_length-1.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions