diff --git a/quanto/library/ext/README.md b/quanto/library/ext/README.md index 8009519c..f2b59a97 100644 --- a/quanto/library/ext/README.md +++ b/quanto/library/ext/README.md @@ -14,7 +14,7 @@ The operations are defined in `library/ops.py`. To provide an implementation for specific device types, use the following syntax: -``` +```python @torch.library.impl("quanto_ext::unpack", ["CPU", "CUDA"]) def unpack(packed: torch.Tensor, bits: int) -> torch.Tensor: return ext().unpack(t, bits) diff --git a/quanto/library/python/README.md b/quanto/library/python/README.md index bc270fc0..8c33eda0 100644 --- a/quanto/library/python/README.md +++ b/quanto/library/python/README.md @@ -8,7 +8,7 @@ The operations are defined in `library/ops.py`. To provide an implementation for an operation, use the following syntax: -``` +```python @torch.library.impl("quanto_py::unpack", "default") def unpack(packed: torch.Tensor, bits: int) -> torch.Tensor: ...