class_docstr: Holds the data and list of :attr:`batch_sizes` of a packed sequence.
  
  All RNN modules accept packed sequences as inputs.
  
  Note:
      Instances of this class should never be created manually. They are meant
      to be instantiated by functions like :func:`pack_padded_sequence`.
  
      Batch sizes represent the number elements at each sequence step in
      the batch, not the varying sequence lengths passed to
      :func:`pack_padded_sequence`.  For instance, given data ``abc`` and ``x``
      the :class:`PackedSequence` would contain data ``axbc`` with
      ``batch_sizes=[2,1,1]``.
  
  Attributes:
      data (Tensor): Tensor containing packed sequence
      batch_sizes (Tensor): Tensor of integers holding
          information about the batch size at each sequence step
      sorted_indices (Tensor, optional): Tensor of integers holding how this
          :class:`PackedSequence` is constructed from sequences.
      unsorted_indices (Tensor, optional): Tensor of integers holding how this
          to recover the original sequences with correct order.
  
  .. note::
      :attr:`data` can be on arbitrary device and of arbitrary dtype.
      :attr:`sorted_indices` and :attr:`unsorted_indices` must be ``torch.int64``
      tensors on the same device as :attr:`data`.
  
      However, :attr:`batch_sizes` should always be a CPU ``torch.int64`` tensor.
  
      This invariant is maintained throughout :class:`PackedSequence` class,
      and all functions that construct a `:class:PackedSequence` in PyTorch
      (i.e., they only pass in tensors conforming to this constraint).
class_docstr_tok: ["Holds","the","data","and","list","of",":","attr",":","`","batch_sizes","`","of","a","packed","sequence",".","All","RNN","modules","accept","packed","sequences","as","inputs",".","Note",":","Instances","of","this","class","should","never","be","created","manually",".","They","are","meant","to","be","instantiated","by","functions","like",":","func",":","`","pack_padded_sequence","`",".","Batch","sizes","represent","the","number","elements","at","each","sequence","step","in","the","batch",",","not","the","varying","sequence","lengths","passed","to",":","func",":","`","pack_padded_sequence","`",".","For","instance",",","given","data","``","abc","``","and","``","x","``","the",":","class",":","`","PackedSequence","`","would","contain","data","``","axbc","``","with","``","batch_sizes=","[","2,1,1","]","``",".","Attributes",":","data","(","Tensor",")",":","Tensor","containing","packed","sequence","batch_sizes","(","Tensor",")",":","Tensor","of","integers","holding","information","about","the","batch","size","at","each","sequence","step","sorted_indices","(","Tensor",",","optional",")",":","Tensor","of","integers","holding","how","this",":","class",":","`","PackedSequence","`","is","constructed","from","sequences",".","unsorted_indices","(","Tensor",",","optional",")",":","Tensor","of","integers","holding","how","this","to","recover","the","original","sequences","with","correct","order",".","..","note",":",":",":","attr",":","`","data","`","can","be","on","arbitrary","device","and","of","arbitrary","dtype",".",":","attr",":","`","sorted_indices","`","and",":","attr",":","`","unsorted_indices","`","must","be","``","torch.int64","``","tensors","on","the","same","device","as",":","attr",":","`","data","`",".","However",",",":","attr",":","`","batch_sizes","`","should","always","be","a","CPU","``","torch.int64","``","tensor",".","This","invariant","is","maintained","throughout",":","class",":","`","PackedSequence","`","class",",","and","all","functions","that","construct","a","`",":","class",":","PackedSequence","`","in","PyTorch","(","i.e.",",","they","only","pass","in","tensors","conforming","to","this","constraint",")","."]
code: def double(self):
      return self.to(dtype=torch.double)
  
imports: import warnings
  from typing import Iterable, List, NamedTuple, Tuple, Union
  import torch
  from torch import Tensor
  from ...None import _VF
  from ..._jit_internal import Optional
label_desc: Use image node_id 5 for calling the PackedSequence obj's underlying member method code with example usage: obj.double() and returns: self