Reduce Glm4v model test size significantly (#39173)
Some checks are pending
Self-hosted runner (benchmark) / Benchmark (aws-g5-4xlarge-cache) (push) Waiting to run
Build documentation / build (push) Waiting to run
New model PR merged notification / Notify new model (push) Waiting to run
Slow tests on important models (on Push - A10) / Get all modified files (push) Waiting to run
Slow tests on important models (on Push - A10) / Slow & FA2 tests (push) Blocked by required conditions
Self-hosted runner (push-caller) / Check if setup was changed (push) Waiting to run
Self-hosted runner (push-caller) / build-docker-containers (push) Blocked by required conditions
Self-hosted runner (push-caller) / Trigger Push CI (push) Blocked by required conditions
Secret Leaks / trufflehog (push) Waiting to run
Update Transformers metadata / build_and_package (push) Waiting to run

* fix test size

* Update test_modeling_glm4v.py
This commit is contained in:
Cyril Vallez 2025-07-02 15:55:05 +02:00 committed by GitHub
parent e355c0a11c
commit 2b4a12b5bf
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -69,16 +69,15 @@ class Glm4vVisionText2TextModelTester:
is_training=True,
text_config={
"vocab_size": 99,
"hidden_size": 32,
"intermediate_size": 37,
"num_hidden_layers": 4,
"num_attention_heads": 4,
"num_key_value_heads": 2,
"hidden_size": 16,
"intermediate_size": 22,
"num_hidden_layers": 2,
"num_attention_heads": 2,
"num_key_value_heads": 1,
"output_channels": 64,
"hidden_act": "silu",
"max_position_embeddings": 512,
"rope_scaling": {"type": "default", "mrope_section": [2, 1, 1]},
"max_window_layers": 3,
"rope_theta": 10000,
"tie_word_embeddings": True,
"bos_token_id": 0,
@ -87,11 +86,10 @@ class Glm4vVisionText2TextModelTester:
},
vision_config={
"depth": 2,
"embed_dim": 32,
"hidden_act": "silu",
"hidden_size": 32,
"mlp_ratio": 4,
"num_heads": 4,
"hidden_size": 48,
"out_hidden_size": 16,
"intermediate_size": 22,
"patch_size": 14,
"spatial_merge_size": 1,
"temporal_patch_size": 2,
@ -239,10 +237,6 @@ class Glm4vModelTest(ModelTesterMixin, GenerationTesterMixin, unittest.TestCase)
def test_multi_gpu_data_parallel_forward(self):
pass
@unittest.skip(reason="We cannot configure to output a smaller model.")
def test_model_is_small(self):
pass
@unittest.skip("Error with compilation")
def test_generate_from_inputs_embeds_with_static_cache(self):
pass