Instructions to use kernels-community/quantization-eetq with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Kernels
How to use kernels-community/quantization-eetq with Kernels:
# !pip install kernels from kernels import get_kernel kernel = get_kernel("kernels-community/quantization-eetq") - Notebooks
- Google Colab
- Kaggle
| TORCH_LIBRARY_EXPAND(TORCH_EXTENSION_NAME, ops) { | |
| ops.def("w8_a16_gemm(Tensor input, Tensor weight, Tensor scale) -> Tensor"); | |
| ops.impl("w8_a16_gemm", torch::kCUDA, &w8_a16_gemm_forward_cuda); | |
| ops.def("w8_a16_gemm_(Tensor input, Tensor weight, Tensor scale, Tensor! output," | |
| "int m, int n, int k) -> Tensor"); | |
| ops.impl("w8_a16_gemm_", torch::kCUDA, &w8_a16_gemm_forward_cuda_); | |
| ops.def("preprocess_weights(Tensor origin_weight, bool is_int4) -> Tensor"); | |
| ops.impl("preprocess_weights", torch::kCUDA, &preprocess_weights_cuda); | |
| ops.def("quant_weights(Tensor origin_weight, ScalarType quant_type," | |
| "bool return_unprocessed_quantized_tensor) -> Tensor[]"); | |
| ops.impl("quant_weights", torch::kCPU, &symmetric_quantize_last_axis_of_tensor); | |
| } | |
| REGISTER_EXTENSION(TORCH_EXTENSION_NAME) | |