MCPcopy Create free account
hub / github.com/deepspeedai/DeepSpeed / extra_repr

Method extra_repr

deepspeed/module_inject/layers.py:642–649  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

640 return new_obj
641
642 def extra_repr(self):
643 out_features, in_features = None, None
644 if self.weight is not None:
645 out_features, in_features = self.weight.ds_shape[-2:] if is_zero_param(
646 self.weight) else self.weight.shape[-2:]
647 dtype = self.weight.dtype if self.weight is not None else None
648 return "in_features={}, out_features={}, bias={}, dtype={}".format(in_features, out_features, self.bias
649 is not None, dtype)
650
651 def move(self, tensor):
652 # TODO: consider the timing of deletion

Callers

nothing calls this directly

Calls 1

is_zero_paramFunction · 0.90

Tested by

no test coverage detected