original_docstring: 
      Wraps hidden states in new Variables, to detach them from their history.
      
docstring: Wraps hidden states in new Variables, to detach them from their history.
docstring_tokens: Wraps hidden states in new Variables to detach them from their history .
code: def repackage_hidden(h):
      """
      Wraps hidden states in new Variables, to detach them from their history.
      """
      if isinstance(h, torch.Tensor):
          return h.detach()
      else:
          return tuple(v.detach() for v in h)
code_tokens: def repackage_hidden ( h ) : if isinstance ( h , torch . Tensor ) : return h . detach ( ) else : return tuple ( v . detach ( ) for v in h )
short_docstring: Wraps hidden states in new Variables, to detach them from their history.
short_docstring_tokens: Wraps hidden states in new Variables to detach them from their history .
comment: """
      Wraps hidden states in new Variables, to detach them from their history.
      """