[None][fix] Remove HF cache dependency from Skywork-R1V2 unit tests#242
Merged
govind-ramnarayan merged 2 commits intoMar 12, 2026
Merged
Conversation
Replace SkyworkChatConfig (loaded via AutoConfig with trust_remote_code, which requires the checkpoint in the local HF cache) with a plain Qwen2Config passed directly to SkyworkR1V2ForConditionalGeneration. The model's __init__ already has a fallback: llm_config = getattr(config, "llm_config", config) so passing Qwen2Config directly works without any wrapper config. The vision tower is simply not instantiated (no vision_config attr). This makes all tests runnable in CI without requiring the full 38B checkpoint in the local HF cache. Signed-off-by: Govind Ramnarayan <105831528+govind-ramnarayan@users.noreply.github.com>
Replace AutoConfig.from_pretrained(..., local_files_only=True) with minimal faithful copies of SkyworkChatConfig and SkyworkVisionConfig defined in the test file (same pattern used for HF modeling classes not in transformers). This removes the module-level pytest.skip that silently skipped all Skywork tests in CI when the 38B checkpoint was absent. Tests now run without any HF checkpoint, while still exercising the real config- wrapping behavior (nested llm_config, vision_config, vision weight keys). Signed-off-by: Govind Ramnarayan <105831528+govind-ramnarayan@users.noreply.github.com>
54a2eeb
into
feat/paperclip_maximizer
2 of 3 checks passed
bmarimuthu-nv
pushed a commit
that referenced
this pull request
Mar 13, 2026
…242) * [None][fix] Remove HF cache dependency from Skywork-R1V2 unit tests Replace SkyworkChatConfig (loaded via AutoConfig with trust_remote_code, which requires the checkpoint in the local HF cache) with a plain Qwen2Config passed directly to SkyworkR1V2ForConditionalGeneration. The model's __init__ already has a fallback: llm_config = getattr(config, "llm_config", config) so passing Qwen2Config directly works without any wrapper config. The vision tower is simply not instantiated (no vision_config attr). This makes all tests runnable in CI without requiring the full 38B checkpoint in the local HF cache. Signed-off-by: Govind Ramnarayan <105831528+govind-ramnarayan@users.noreply.github.com> * [None][fix] Remove HF cache dependency from Skywork-R1V2 unit tests Replace AutoConfig.from_pretrained(..., local_files_only=True) with minimal faithful copies of SkyworkChatConfig and SkyworkVisionConfig defined in the test file (same pattern used for HF modeling classes not in transformers). This removes the module-level pytest.skip that silently skipped all Skywork tests in CI when the 38B checkpoint was absent. Tests now run without any HF checkpoint, while still exercising the real config- wrapping behavior (nested llm_config, vision_config, vision weight keys). Signed-off-by: Govind Ramnarayan <105831528+govind-ramnarayan@users.noreply.github.com> --------- Signed-off-by: Govind Ramnarayan <105831528+govind-ramnarayan@users.noreply.github.com>
bmarimuthu-nv
pushed a commit
that referenced
this pull request
Mar 13, 2026
…242) * [None][fix] Remove HF cache dependency from Skywork-R1V2 unit tests Replace SkyworkChatConfig (loaded via AutoConfig with trust_remote_code, which requires the checkpoint in the local HF cache) with a plain Qwen2Config passed directly to SkyworkR1V2ForConditionalGeneration. The model's __init__ already has a fallback: llm_config = getattr(config, "llm_config", config) so passing Qwen2Config directly works without any wrapper config. The vision tower is simply not instantiated (no vision_config attr). This makes all tests runnable in CI without requiring the full 38B checkpoint in the local HF cache. Signed-off-by: Govind Ramnarayan <105831528+govind-ramnarayan@users.noreply.github.com> * [None][fix] Remove HF cache dependency from Skywork-R1V2 unit tests Replace AutoConfig.from_pretrained(..., local_files_only=True) with minimal faithful copies of SkyworkChatConfig and SkyworkVisionConfig defined in the test file (same pattern used for HF modeling classes not in transformers). This removes the module-level pytest.skip that silently skipped all Skywork tests in CI when the 38B checkpoint was absent. Tests now run without any HF checkpoint, while still exercising the real config- wrapping behavior (nested llm_config, vision_config, vision weight keys). Signed-off-by: Govind Ramnarayan <105831528+govind-ramnarayan@users.noreply.github.com> --------- Signed-off-by: Govind Ramnarayan <105831528+govind-ramnarayan@users.noreply.github.com>
bmarimuthu-nv
pushed a commit
that referenced
this pull request
Mar 14, 2026
…242) * [None][fix] Remove HF cache dependency from Skywork-R1V2 unit tests Replace SkyworkChatConfig (loaded via AutoConfig with trust_remote_code, which requires the checkpoint in the local HF cache) with a plain Qwen2Config passed directly to SkyworkR1V2ForConditionalGeneration. The model's __init__ already has a fallback: llm_config = getattr(config, "llm_config", config) so passing Qwen2Config directly works without any wrapper config. The vision tower is simply not instantiated (no vision_config attr). This makes all tests runnable in CI without requiring the full 38B checkpoint in the local HF cache. Signed-off-by: gramnarayan <105831528+govind-ramnarayan@users.noreply.github.com> * [None][fix] Remove HF cache dependency from Skywork-R1V2 unit tests Replace AutoConfig.from_pretrained(..., local_files_only=True) with minimal faithful copies of SkyworkChatConfig and SkyworkVisionConfig defined in the test file (same pattern used for HF modeling classes not in transformers). This removes the module-level pytest.skip that silently skipped all Skywork tests in CI when the 38B checkpoint was absent. Tests now run without any HF checkpoint, while still exercising the real config- wrapping behavior (nested llm_config, vision_config, vision weight keys). Signed-off-by: gramnarayan <105831528+govind-ramnarayan@users.noreply.github.com> --------- Signed-off-by: gramnarayan <105831528+govind-ramnarayan@users.noreply.github.com>
bmarimuthu-nv
pushed a commit
that referenced
this pull request
Mar 18, 2026
…242) * [None][fix] Remove HF cache dependency from Skywork-R1V2 unit tests Replace SkyworkChatConfig (loaded via AutoConfig with trust_remote_code, which requires the checkpoint in the local HF cache) with a plain Qwen2Config passed directly to SkyworkR1V2ForConditionalGeneration. The model's __init__ already has a fallback: llm_config = getattr(config, "llm_config", config) so passing Qwen2Config directly works without any wrapper config. The vision tower is simply not instantiated (no vision_config attr). This makes all tests runnable in CI without requiring the full 38B checkpoint in the local HF cache. Signed-off-by: gramnarayan <105831528+govind-ramnarayan@users.noreply.github.com> * [None][fix] Remove HF cache dependency from Skywork-R1V2 unit tests Replace AutoConfig.from_pretrained(..., local_files_only=True) with minimal faithful copies of SkyworkChatConfig and SkyworkVisionConfig defined in the test file (same pattern used for HF modeling classes not in transformers). This removes the module-level pytest.skip that silently skipped all Skywork tests in CI when the 38B checkpoint was absent. Tests now run without any HF checkpoint, while still exercising the real config- wrapping behavior (nested llm_config, vision_config, vision weight keys). Signed-off-by: gramnarayan <105831528+govind-ramnarayan@users.noreply.github.com> --------- Signed-off-by: gramnarayan <105831528+govind-ramnarayan@users.noreply.github.com>
bmarimuthu-nv
pushed a commit
that referenced
this pull request
Mar 25, 2026
…242) * [None][fix] Remove HF cache dependency from Skywork-R1V2 unit tests Replace SkyworkChatConfig (loaded via AutoConfig with trust_remote_code, which requires the checkpoint in the local HF cache) with a plain Qwen2Config passed directly to SkyworkR1V2ForConditionalGeneration. The model's __init__ already has a fallback: llm_config = getattr(config, "llm_config", config) so passing Qwen2Config directly works without any wrapper config. The vision tower is simply not instantiated (no vision_config attr). This makes all tests runnable in CI without requiring the full 38B checkpoint in the local HF cache. Signed-off-by: gramnarayan <105831528+govind-ramnarayan@users.noreply.github.com> * [None][fix] Remove HF cache dependency from Skywork-R1V2 unit tests Replace AutoConfig.from_pretrained(..., local_files_only=True) with minimal faithful copies of SkyworkChatConfig and SkyworkVisionConfig defined in the test file (same pattern used for HF modeling classes not in transformers). This removes the module-level pytest.skip that silently skipped all Skywork tests in CI when the 38B checkpoint was absent. Tests now run without any HF checkpoint, while still exercising the real config- wrapping behavior (nested llm_config, vision_config, vision weight keys). Signed-off-by: gramnarayan <105831528+govind-ramnarayan@users.noreply.github.com> --------- Signed-off-by: gramnarayan <105831528+govind-ramnarayan@users.noreply.github.com>
bmarimuthu-nv
pushed a commit
that referenced
this pull request
Apr 1, 2026
…242) * [None][fix] Remove HF cache dependency from Skywork-R1V2 unit tests Replace SkyworkChatConfig (loaded via AutoConfig with trust_remote_code, which requires the checkpoint in the local HF cache) with a plain Qwen2Config passed directly to SkyworkR1V2ForConditionalGeneration. The model's __init__ already has a fallback: llm_config = getattr(config, "llm_config", config) so passing Qwen2Config directly works without any wrapper config. The vision tower is simply not instantiated (no vision_config attr). This makes all tests runnable in CI without requiring the full 38B checkpoint in the local HF cache. Signed-off-by: gramnarayan <105831528+govind-ramnarayan@users.noreply.github.com> * [None][fix] Remove HF cache dependency from Skywork-R1V2 unit tests Replace AutoConfig.from_pretrained(..., local_files_only=True) with minimal faithful copies of SkyworkChatConfig and SkyworkVisionConfig defined in the test file (same pattern used for HF modeling classes not in transformers). This removes the module-level pytest.skip that silently skipped all Skywork tests in CI when the 38B checkpoint was absent. Tests now run without any HF checkpoint, while still exercising the real config- wrapping behavior (nested llm_config, vision_config, vision weight keys). Signed-off-by: gramnarayan <105831528+govind-ramnarayan@users.noreply.github.com> --------- Signed-off-by: gramnarayan <105831528+govind-ramnarayan@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
SkyworkChatConfig(loaded viaAutoConfig.from_pretrainedwithtrust_remote_code, requiring the 38B checkpoint in local HF cache) with a plainQwen2Configpassed directly toSkyworkR1V2ForConditionalGenerationpytest.skipthat skipped all tests when the checkpoint was absent — all tests now run in CI without any checkpoint_create_small_chat_config()helper; all tests use_create_small_llm_config()directlyThe model's
__init__already has agetattr(config, "llm_config", config)fallback, soQwen2Configworks as-is. No vision tower is instantiated (novision_configattr onQwen2Config).Test plan
test_skywork_r1v2_config_qwen2_fallbackverifies the directQwen2Configpathtest_skywork_r1v2_state_dict_keysupdated to only assertlanguage_model.*keys (no vision)🤖 Generated with Claude Code