src/transformers/models/marian/modeling_tf_marian.py/TFMarianSinusoidalPositionalEmbedding/call
class TFMarianSinusoidalPositionalEmbedding:    def call(
        self, input_shape: tf.TensorShape, past_key_values_length: int = 0, position_ids: Optional[tf.Tensor] = None
    ):
        """Input is expected to be of size [bsz x seqlen]."""
        if position_ids is None:
            seq_len = input_shape[1]
            position_ids = tf.range(past_key_values_length, seq_len + past_key_values_length, delta=1, name="range")
        return tf.gather(self.weight, position_ids)