Upload configuration_gemmagain.py with huggingface_hub
Browse files
configuration_gemmagain.py
CHANGED
|
@@ -12,7 +12,7 @@
|
|
| 12 |
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
| 13 |
# See the License for the specific language governing permissions and
|
| 14 |
# limitations under the License.
|
| 15 |
-
"""
|
| 16 |
|
| 17 |
from transformers.configuration_utils import PretrainedConfig, layer_type_validation
|
| 18 |
from transformers.modeling_rope_utils import rope_config_validation
|
|
@@ -22,9 +22,9 @@ from transformers.utils import logging
|
|
| 22 |
logger = logging.get_logger(__name__)
|
| 23 |
|
| 24 |
|
| 25 |
-
class
|
| 26 |
r"""
|
| 27 |
-
Configuration class for
|
| 28 |
|
| 29 |
This extends Gemma3TextConfig to add the `layer_sequence` parameter which controls
|
| 30 |
how layers are executed, allowing layers to be repeated multiple times.
|
|
@@ -183,4 +183,4 @@ class GemmagainConfig(PretrainedConfig):
|
|
| 183 |
layer_type_validation(self.layer_types, self.num_hidden_layers)
|
| 184 |
|
| 185 |
|
| 186 |
-
__all__ = ["
|
|
|
|
| 12 |
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
| 13 |
# See the License for the specific language governing permissions and
|
| 14 |
# limitations under the License.
|
| 15 |
+
"""Gemma3 model configuration - Gemma3 with layer looping support"""
|
| 16 |
|
| 17 |
from transformers.configuration_utils import PretrainedConfig, layer_type_validation
|
| 18 |
from transformers.modeling_rope_utils import rope_config_validation
|
|
|
|
| 22 |
logger = logging.get_logger(__name__)
|
| 23 |
|
| 24 |
|
| 25 |
+
class Gemma3Config(PretrainedConfig):
|
| 26 |
r"""
|
| 27 |
+
Configuration class for Gemma3 - a Gemma3 text model with layer looping support.
|
| 28 |
|
| 29 |
This extends Gemma3TextConfig to add the `layer_sequence` parameter which controls
|
| 30 |
how layers are executed, allowing layers to be repeated multiple times.
|
|
|
|
| 183 |
layer_type_validation(self.layer_types, self.num_hidden_layers)
|
| 184 |
|
| 185 |
|
| 186 |
+
__all__ = ["Gemma3Config"]
|