Skip to content

test(quant): skip declined local checkpoints and label cache paths portably - #582

Draft
YevheniiKotyrlo wants to merge 1 commit into
FlashML-org:mainfrom
YevheniiKotyrlo:fix-test-quant-config-local-checkpoints
Draft

YevheniiKotyrlo wants to merge 1 commit into
FlashML-org:mainfrom
YevheniiKotyrlo:fix-test-quant-config-local-checkpoints

Conversation

@YevheniiKotyrlo

@YevheniiKotyrlo YevheniiKotyrlo commented Sep 30, 2026 •

Copy link
Copy Markdown
Contributor

Problem

test_scheme_for_agrees_with_the_stored_tensors runs over every checkpoint in the local Hugging Face cache and /mnt/nvme/models, so what is on the machine decides whether it passes. Two things fail it for reasons outside the code under test:

  1. A checkpoint whose quantization method FreeToken supports but whose scheme it declines - here a compressed-tensors W4A16 snapshot (int4, group 128) - raises NotImplementedError: compressed-tensors weight scheme {...} is not supported from QuantConfig.from_hf. The test expects that only for methods in _UNSUPPORTED.
  2. _label finds the repo with models--([^/]+)/snapshots, which never matches a Windows path, so every cache entry is labelled nvme:<snapshot hash>.

Solution

A NotImplementedError from from_hf skips the row and says why - a clean decline is the behaviour a declined scheme should have, and the skip keeps it visible under -rs. _label reads the repo from the path's parts, which is right on every platform.

Verification

Windows 11, with the W4A16 snapshot in the cache: before, 1 failed as [nvme:124c14e7e8c7d2f5402933b9af368e772a9fcf0c[index-only]]; after, the row is [syvai/qwen3.8-27b-3090-fast-variant[index-only]] and skips with FreeToken declines this checkpoint: compressed-tensors weight scheme {...} is not supported. pytest tests/models/test_quant_config.py: 11 passed, 42 skipped; on Linux, whose cache holds no declined checkpoint, 11 passed and 42 skipped with or without this change.

@YevheniiKotyrlo
YevheniiKotyrlo force-pushed the fix-test-quant-config-local-checkpoints branch from 64827fd to 5374f7e Compare October 6, 2026 10:54
KarrAcaRn pushed a commit to KarrAcaRn/FreeToken-ByAI that referenced this pull request Oct 6, 2026
FlashML-org#618 deferred with FlashML-org#605 (pre-sm70 only); drafts FlashML-org#582, FlashML-org#583, FlashML-org#586, FlashML-org#613 deferred.

Assisted-by: Claude Opus 5.5
KarrAcaRn pushed a commit to KarrAcaRn/FreeToken-ByAI that referenced this pull request Oct 6, 2026
FlashML-org#586

A stale local pr/N ref (fetched without + before a rebase) gave their pre-rebase SHAs;
the rebased heads carry the same changes.

Assisted-by: Claude Opus 5.5
@YevheniiKotyrlo
YevheniiKotyrlo force-pushed the fix-test-quant-config-local-checkpoints branch from 5374f7e to d2e4d10 Compare October 13, 2026 14:06

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant