transformers/tests/quantization
David LaPalomento b45cf0e90a
Guard against unset resolved_archive_file (#35628)
* archive_file may not be specified
When loading a pre-trained model from a gguf file, resolved_archive_file may not be set. Guard against that case in the safetensors availability check.

* Remap partial disk offload to cpu for GGUF files
GGUF files don't support disk offload so attempt to remap them to the CPU when device_map is auto. If device_map is anything else but None, raise a NotImplementedError.

* Don't remap auto device_map and raise RuntimeError
If device_map=auto and modules are selected for disk offload, don't attempt to map them to any other device. Raise a runtime error when a GGUF model is configured to map any modules to disk.

---------

Co-authored-by: Marc Sun <57196510+SunMarc@users.noreply.github.com>
2025-02-14 14:44:31 +01:00
..
aqlm_integration Skipping aqlm non working inference tests till fix merged (#34865) 2024-11-26 11:09:30 +01:00
autoawq Enables CPU AWQ model with IPEX version. (#33460) 2024-10-04 16:25:10 +02:00
bitnet_integration Fix : BitNet tests (#34895) 2024-11-25 16:47:14 +01:00
bnb use torch.testing.assertclose instead to get more details about error in cis (#35659) 2025-01-24 16:55:28 +01:00
compressed_tensor Run model as compressed/uncompressed mode (#34719) 2024-12-13 08:23:31 +01:00
eetq_integration Fix typo in EETQ Tests (#35160) 2024-12-09 14:13:36 +01:00
fbgemm_fp8 Fix FbgemmFp8Linear not preserving tensor shape (#33239) 2024-09-11 13:26:44 +02:00
finegrained_fp8 Add require_read_token to fp8 tests (#36189) 2025-02-14 12:27:35 +01:00
ggml Guard against unset resolved_archive_file (#35628) 2025-02-14 14:44:31 +01:00
gptq Enable gptqmodel (#35012) 2025-01-15 14:22:49 +01:00
higgs New HIGGS quantization interfaces, JIT kernel compilation support. (#36148) 2025-02-14 12:26:45 +01:00
hqq Fix : HQQ config when hqq not available (#35655) 2025-01-14 11:37:37 +01:00
quanto_integration [tests] make cuda-only tests device-agnostic (#35607) 2025-01-13 14:48:39 +01:00
spqr_integration Efficient Inference Kernel for SpQR (#34976) 2025-02-13 16:22:58 +01:00
torchao_integration Fix CI by tweaking torchao tests (#34832) 2024-11-20 20:28:51 +01:00
vptq_integration Fix : VPTQ test (#35394) 2024-12-23 16:27:46 +01:00