Downloads · 30 days
104
9% of all-time downloads
VaslD/mmproj-Gemma-4-31B-StyleTune-GGUF
mmproj-Gemma-4-31B-StyleTune-GGUF is a machine learning model from VaslD. Use it for the machine learning task on the model card, and read the license before you ship it in a product.
Patch required to extract vision tower of Gemma 4 with separated lmhead:
Downloads · 30 days
104
9% of all-time downloads
All-time downloads
1.1K
Public
Repo size
1.2 GB
Likes
1
Public
Click a slice to open those files.
.gguf1.2 GB · 100%
From the Hugging Face model README
Patch required to extract vision tower of Gemma 4 with separated lm_head:
diff --git srcPrefix/conversion/gemma.py dstPrefix/conversion/gemma.py
index 5b4ca5c583df0f44b43ca1176e51dc9d7c3815b1..cef52be819c00a80775ad7d387db424048b9992a 100644
--- srcPrefix/conversion/gemma.py
+++ dstPrefix/conversion/gemma.py
@@ -882,6 +882,15 @@ class Gemma4VisionAudioModel(MmprojModel):
mapped_name = self.map_tensor_name(name, (".weight", ".bias", ".input_max", ".input_min", ".output_max", ".output_min"))
yield (mapped_name, data_torch)
+ @classmethod
+ def filter_tensors(cls, item: tuple[str, Callable[[], Tensor]]) -> tuple[str, Callable[[], Tensor]] | None:
+ # Gryphe/Gemma-4-31B-StyleTune patch
+ name, _ = item
+ if name == "lm_head.weight":
+ return None
+
+ return super().filter_tensors(item)
+
@ModelBase.register("Gemma4UnifiedForConditionalGeneration")
class Gemma4UnifiedVisionAudioModel(Gemma4VisionAudioModel):