Shieldgemma2 (#36678)
* single commit * correct config * fixup * dummy pt * Use ShieldGemma2Config in conversion script * Update src/transformers/models/shieldgemma2/configuration_shieldgemma2.py * Adding shieldgemma2 to models.__init__.py * Adding ShieldGemma2 to main __init__.py * Update shieldgemma2.md * Update shieldgemma2.md * Adding tests. Addressing review feedback. * Minor docs update * Fixing code quality feedback from CI * Fixing empty messages bug reported by ghunkins --------- Co-authored-by: Arthur Zucker <arthur.zucker@gmail.com> Co-authored-by: Ren Pang <ain-soph@live.com>
This commit is contained in:
@@ -228,6 +228,14 @@ SPECIAL_CASES_TO_ALLOW = {
|
||||
"GPTNeoXConfig": ["rotary_emb_base"],
|
||||
"Gemma3Config": ["boi_token_index", "eoi_token_index"],
|
||||
"Gemma3TextConfig": ["cache_implementation", "tie_word_embeddings"],
|
||||
"ShieldGemma2Config": [
|
||||
"boi_token_index",
|
||||
"eoi_token_index",
|
||||
"initializer_range",
|
||||
"mm_tokens_per_image",
|
||||
"text_config",
|
||||
"vision_config",
|
||||
],
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -167,6 +167,7 @@ TEST_FILES_WITH_NO_COMMON_TESTS = [
|
||||
"models/vision_text_dual_encoder/test_modeling_flax_vision_text_dual_encoder.py",
|
||||
"models/decision_transformer/test_modeling_decision_transformer.py",
|
||||
"models/bark/test_modeling_bark.py",
|
||||
"models/shieldgemma2/test_modeling_shieldgemma2.py",
|
||||
]
|
||||
|
||||
# Update this list for models that are not in any of the auto MODEL_XXX_MAPPING. Being in this list is an exception and
|
||||
|
||||
Reference in New Issue
Block a user