Tok2vec loss is growing in TextCategorizer #12317
Replies: 2 comments 3 replies
-
HI @chisuikafuku! You mention that the |
Beta Was this translation helpful? Give feedback.
-
Hi everyone 👋 I thought about reactivating this discussion ticket instead of creating a new one, since it seems very related... I'm training a text classification model using spaCy v3 with the pipeline ["tok2vec", "textcat"]. Specifically, I'm using TextCatParametricAttention.v1 as the classifier, and I'm initializing the tok2vec component from the pretrained German model de_core_news_lg. During training, I noticed the following: LOSS TEXTCAT steadily decreases over time (as expected) My classification metrics (e.g., macro F1, precision, recall) are improving But LOSS TOK2VEC is increasing, quite significantly, from near-zero up to 1600+ over a few thousand steps Here’s a small excerpt from the training logs: My Understanding So Far
My Questions
|
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Hi,
First of all, thank you for your work, I love using Spacy !
I’m actually working on emails classification with spacy. Here the steps I followed :
init config
command. So my pipeline include a trainable tok2vec component in the TextCategorizer model.Here’s the thing. I tried two trainings with the « long » french spacy model as starting point :
First : initial word vectors (output of init config cmd)
Second : initial word vectors + pretrained tok2vec
In both scenarios my tok2vec loss is decreasing during the first steps and after that it is growing… (from 5 to 300 !) I don’t understand why.
Best
Beta Was this translation helpful? Give feedback.
All reactions