From 5fae577afd615d92cea8b8c8e72e07508d823b61 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Martyna=20Wi=C4=85cek?= <martyna.wiacek@ipipan.waw.pl>
Date: Sat, 3 Feb 2024 23:48:10 +0100
Subject: [PATCH] fixed name of gelu function

---
 combo/default_model.py  | 8 ++++----
 combo/nn/activations.py | 2 +-
 2 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/combo/default_model.py b/combo/default_model.py
index d074e62..f02786b 100644
--- a/combo/default_model.py
+++ b/combo/default_model.py
@@ -19,7 +19,7 @@ from combo.modules.morpho import MorphologicalFeatures
 from combo.modules.parser import DependencyRelationModel, HeadPredictionModel
 from combo.modules.text_field_embedders import BasicTextFieldEmbedder
 from combo.modules.token_embedders import CharacterBasedWordEmbedder, TransformersWordEmbedder
-from combo.nn.activations import ReLUActivation, TanhActivation, LinearActivation
+from combo.nn.activations import ReLUActivation, TanhActivation, LinearActivation, GELUActivation
 from combo.modules import FeedForwardPredictor
 from combo.nn.base import Linear
 from combo.nn.regularizers.regularizers import L2Regularizer
@@ -128,10 +128,10 @@ def default_model(pretrained_transformer_name: str, vocabulary: Vocabulary) -> C
         ),
         lemmatizer=LemmatizerModel(
             vocabulary=vocabulary,
-            activations=[ReLUActivation(), ReLUActivation(), ReLUActivation(), LinearActivation()],
+            activations=[GELUActivation(), GELUActivation(), GELUActivation(), LinearActivation()],
             char_vocab_namespace="token_characters",
             dilation=[1, 2, 4, 1],
-            embedding_dim=256,
+            embedding_dim=300,
             filters=[256, 256, 256],
             input_projection_layer=Linear(
                 activation=TanhActivation(),
@@ -183,7 +183,7 @@ def default_model(pretrained_transformer_name: str, vocabulary: Vocabulary) -> C
                 "char": CharacterBasedWordEmbedder(
                     vocabulary=vocabulary,
                     dilated_cnn_encoder=DilatedCnnEncoder(
-                        activations=[ReLUActivation(), ReLUActivation(), LinearActivation()],
+                        activations=[GELUActivation(), GELUActivation(), LinearActivation()],
                         dilation=[1, 2, 4],
                         filters=[512, 256, 64],
                         input_dim=64,
diff --git a/combo/nn/activations.py b/combo/nn/activations.py
index f4e5d43..60f64aa 100644
--- a/combo/nn/activations.py
+++ b/combo/nn/activations.py
@@ -39,7 +39,7 @@ class ReLUActivation(Activation):
 
 
 @Registry.register('gelu')
-class ReLUActivation(Activation):
+class GELUActivation(Activation):
     def __init__(self):
         super().__init__()
         self.__torch_activation = torch.nn.GELU()
-- 
GitLab