MCPcopy Create free account
hub / github.com/huggingface/transformers / detach

Method detach

examples/seq2seq/bertabs/modeling_bertabs.py:541–544  ·  view source on GitHub ↗

Need to document this

(self)

Source from the content-addressed store, hash-verified

539 """
540
541 def detach(self):
542 """ Need to document this """
543 self.hidden = tuple([_.detach() for _ in self.hidden])
544 self.input_feed = self.input_feed.detach()
545
546 def beam_update(self, idx, positions, beam_size):
547 """ Need to document this """

Callers 15

to_listFunction · 0.45
cache_memMethod · 0.45
prune_linear_layerFunction · 0.45
prune_conv1d_layerFunction · 0.45
_update_memsMethod · 0.45
_hash_vectorsMethod · 0.45
backward_passMethod · 0.45
forwardMethod · 0.45
_prediction_loopMethod · 0.45
__call__Method · 0.45
test_mnli_inferenceMethod · 0.45

Calls

no outgoing calls