[Compressed Tensors] Always clone output for compile robustness (#26849)

Signed-off-by: Kyle Sayers <kylesayrs@gmail.com>
Co-authored-by: Michael Goin <mgoin64@gmail.com>
This commit is contained in:
Kyle Sayers 2025-10-16 15:29:59 -04:00 committed by GitHub
parent ac3ed5a815
commit a5464dcf92
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -163,7 +163,7 @@ class CompressedTensorsLinearTransformMethod(LinearMethodBase):
if self.output_transform is not None:
for part_id, (start, length) in enumerate(self.partition_ranges):
x[:, start : start + length] = self.output_transform(
x[:, start : start + length].contiguous(), part_id=part_id
x[:, start : start + length].clone(), part_id=part_id
)
return x