MCPcopy
hub / github.com/tinygrad/tinygrad / ref

Method ref

tinygrad/device.py:93–95  ·  view source on GitHub ↗
(self, cnt)

Source from the content-addressed store, hash-verified

91 @property
92 def dtype(self): return self.bufs[0].dtype
93 def ref(self, cnt):
94 for b in self.bufs: b.ref(cnt)
95 return self
96 def is_allocated(self): return all(x.is_allocated() for x in self.bufs)
97 def __repr__(self): return f"<multibuf real:{self.is_allocated()} device:{tuple(x.device for x in self.bufs)} size:{self.size} dtype:{self.dtype}>"
98

Callers

nothing calls this directly

Calls 1

refMethod · 0.45

Tested by

no test coverage detected