docs: def length(self, rows=None):
      """Tensor holding the current length of episodes.
  
      Args:
        rows: Episodes to select length from, defaults to all.
  
      Returns:
        Batch tensor of sequence lengths.
      """
      rows = tf.range(self._capacity) if rows is None else rows
      return tf.gather(self._length, rows)