philipp-zettl
commited on
Commit
•
79c7b39
1
Parent(s):
f336dab
Upload folder using huggingface_hub
Browse files- README.md +13 -12
- assets/confusion_matrix_GGU.png +0 -0
- assets/confusion_matrix_sentiment.png +0 -0
- assets/loss_plot_GGU.png +0 -0
- assets/loss_plot_sentiment.png +0 -0
- heads/GGU.pth +1 -1
- heads/sentiment.pth +1 -1
- multi-head-sequence-classification-model-model.pth +1 -1
README.md
CHANGED
@@ -165,7 +165,7 @@ def train_classifier():
|
|
165 |
l2_loss_weight=l2_loss_weight,
|
166 |
use_lr_scheduler=True,
|
167 |
train_run=train_run,
|
168 |
-
auto_find_batch_size=
|
169 |
)
|
170 |
|
171 |
new_model, history = trainer.train(dataset_name='philipp-zettl/GGU-xx', target_heads=['GGU'])
|
@@ -179,7 +179,8 @@ def train_classifier():
|
|
179 |
}
|
180 |
|
181 |
trainer.classifier.add_head('sentiment', 3)
|
182 |
-
|
|
|
183 |
metrics = history['metrics']
|
184 |
history['loss_plot'] = trainer._plot_history(**metrics)
|
185 |
res = trainer.eval({'sentiment': sentiment_label_map}, sample_key='text')
|
@@ -244,18 +245,18 @@ For evaluation, we used the following metrics: accuracy, precision, recall, f1-s
|
|
244 |
**GGU:**
|
245 |
| | index | precision | recall | f1-score | support |
|
246 |
|---:|:-------------|------------:|---------:|-----------:|----------:|
|
247 |
-
| 0 | Greeting | 0.
|
248 |
-
| 1 | Gratitude | 0.
|
249 |
-
| 2 | Other |
|
250 |
-
| 3 | macro avg | 0.
|
251 |
-
| 4 | weighted avg | 0.
|
252 |
|
253 |
**sentiment:**
|
254 |
| | index | precision | recall | f1-score | support |
|
255 |
|---:|:-------------|------------:|---------:|-----------:|----------:|
|
256 |
-
| 0 | Positive | 0.
|
257 |
-
| 1 | Negative | 0.
|
258 |
-
| 2 | Neutral | 0.
|
259 |
-
| 3 | macro avg | 0.
|
260 |
-
| 4 | weighted avg | 0.
|
261 |
|
|
|
165 |
l2_loss_weight=l2_loss_weight,
|
166 |
use_lr_scheduler=True,
|
167 |
train_run=train_run,
|
168 |
+
auto_find_batch_size=False
|
169 |
)
|
170 |
|
171 |
new_model, history = trainer.train(dataset_name='philipp-zettl/GGU-xx', target_heads=['GGU'])
|
|
|
179 |
}
|
180 |
|
181 |
trainer.classifier.add_head('sentiment', 3)
|
182 |
+
trainer.auto_find_batch_size = False
|
183 |
+
new_model, history = trainer.train(dataset_name='philipp-zettl/sentiment', target_heads=['sentiment'], sample_key='text', num_epochs=10, lr=1e-4)
|
184 |
metrics = history['metrics']
|
185 |
history['loss_plot'] = trainer._plot_history(**metrics)
|
186 |
res = trainer.eval({'sentiment': sentiment_label_map}, sample_key='text')
|
|
|
245 |
**GGU:**
|
246 |
| | index | precision | recall | f1-score | support |
|
247 |
|---:|:-------------|------------:|---------:|-----------:|----------:|
|
248 |
+
| 0 | Greeting | 0.904762 | 0.974359 | 0.938272 | 39 |
|
249 |
+
| 1 | Gratitude | 0.958333 | 0.851852 | 0.901961 | 27 |
|
250 |
+
| 2 | Other | 1 | 1 | 1 | 39 |
|
251 |
+
| 3 | macro avg | 0.954365 | 0.94207 | 0.946744 | 105 |
|
252 |
+
| 4 | weighted avg | 0.953912 | 0.952381 | 0.951862 | 105 |
|
253 |
|
254 |
**sentiment:**
|
255 |
| | index | precision | recall | f1-score | support |
|
256 |
|---:|:-------------|------------:|---------:|-----------:|----------:|
|
257 |
+
| 0 | Positive | 0.783088 | 0.861878 | 0.820596 | 12851 |
|
258 |
+
| 1 | Negative | 0.802105 | 0.819524 | 0.810721 | 14229 |
|
259 |
+
| 2 | Neutral | 0.7874 | 0.6913 | 0.736227 | 13126 |
|
260 |
+
| 3 | macro avg | 0.790864 | 0.790901 | 0.789181 | 40206 |
|
261 |
+
| 4 | weighted avg | 0.791226 | 0.7912 | 0.789557 | 40206 |
|
262 |
|
assets/confusion_matrix_GGU.png
CHANGED
assets/confusion_matrix_sentiment.png
CHANGED
assets/loss_plot_GGU.png
CHANGED
assets/loss_plot_sentiment.png
CHANGED
heads/GGU.pth
CHANGED
@@ -1,3 +1,3 @@
|
|
1 |
version https://git-lfs.github.com/spec/v1
|
2 |
-
oid sha256:
|
3 |
size 7552
|
|
|
1 |
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:260a8a942298ea9ff00deebb99e0941f2eceb7174cff2285d29ae670676dacb9
|
3 |
size 7552
|
heads/sentiment.pth
CHANGED
@@ -1,3 +1,3 @@
|
|
1 |
version https://git-lfs.github.com/spec/v1
|
2 |
-
oid sha256:
|
3 |
size 7652
|
|
|
1 |
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:ba5eb9141857c813f7d7c67d57ea53855fbddcc88e96abb1c4ab2829b24f453b
|
3 |
size 7652
|
multi-head-sequence-classification-model-model.pth
CHANGED
@@ -1,3 +1,3 @@
|
|
1 |
version https://git-lfs.github.com/spec/v1
|
2 |
-
oid sha256:
|
3 |
size 1135701541
|
|
|
1 |
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:78657066b5c7091033fd3eec7870fdcc0b7fe98d094ba50aa409e78426720171
|
3 |
size 1135701541
|