remove unused UOp.shard_size [pr] (#15933)

This commit is contained in:
chenyu 2026-04-25 12:27:58 -04:00 committed by GitHub
commit e27444a0ff
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -339,9 +339,6 @@ class UOp(OpMixin, metaclass=UOpMetaClass):
if not isinstance(self.device, tuple) or self.axis is None: return self.max_shape
return tuple(x//len(self.device) if i == self.axis else x for i,x in enumerate(self.max_shape))
@property
def shard_size(self) -> int: return prod(self.max_shard_shape)
@functools.cached_property
def ended_ranges(self) -> tuple[UOp, ...]:
if self.op in range_start: return self.src[range_start[self.op]:]