MCPcopy Create free account
hub / github.com/pytorch/pytorch / _IncompatibleKeys

Class _IncompatibleKeys

torch/nn/modules/module.py:29–35  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

27
28
29class _IncompatibleKeys(namedtuple('IncompatibleKeys', ['missing_keys', 'unexpected_keys'])):
30 def __repr__(self):
31 if not self.missing_keys and not self.unexpected_keys:
32 return '<All keys matched successfully>'
33 return super().__repr__()
34
35 __str__ = __repr__
36
37
38def _addindent(s_, numSpaces):

Callers 3

_load_model_state_dictFunction · 0.90
loadMethod · 0.85
load_state_dictMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…