Skip to content

Fixed SVD interpreter test#1375

Merged
jlarson4 merged 2 commits into
TransformerLensOrg:devfrom
has9800:fix-svd-interpreter-fixtures
Jun 9, 2026
Merged

Fixed SVD interpreter test#1375
jlarson4 merged 2 commits into
TransformerLensOrg:devfrom
has9800:fix-svd-interpreter-fixtures

Conversation

@has9800

@has9800 has9800 commented Jun 9, 2026

Copy link
Copy Markdown

Description

This fixes the SVD interpreter tests that skipped due to the fixtures not always satisfying the test requirements.

I replaced the model fixtures with two distinct GPT2 models from supported_models.json. The primary model is multi-layer and is compatible for the 4 vector SVD comparisons, and the secondary model is distinct so the cross-model test doesnt fall back to using the same model.

The pytest.skip(...) guards are also removed.

Changes:

  • Used Intel/tiny-random-gpt2 as the primary model so the comparison test uses a small multi-layer model.
  • Used hyper-accel/tiny-random-gpt2 as the secondary model so the cross model test uses a distinct model.
  • Removed pytest.skip(...) guards from the two tests.
  • Removed the fallback path that loads the same model for both fixtures.

Result: 7 passed, 2 warnings (dependency deprecation warnings)

Fixes #1327

Type of change

  • Bug fix (non-breaking change which fixes an issue)

Checklist:

  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes
  • I have not rewritten tests relating to key interfaces which would affect backward compatibility

@jlarson4

jlarson4 commented Jun 9, 2026

Copy link
Copy Markdown
Collaborator

@has9800 This looks great, I just need you to run make format so that CI will pass for Format Checks.

If you see any CI runs that 429, just let me know and I can re-run them.

@has9800

has9800 commented Jun 9, 2026

Copy link
Copy Markdown
Author

Hey I've ran make format, no 429 errors luckily, thanks!

@jlarson4

jlarson4 commented Jun 9, 2026

Copy link
Copy Markdown
Collaborator

Excellent! Merging now, thanks for tackling this

@jlarson4 jlarson4 merged commit 34dc38a into TransformerLensOrg:dev Jun 9, 2026
25 checks passed
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.

2 participants