Closed markusgl closed 2 years ago
I have the same issue. After investigating the calculate_class_weights()
implementation it seems like the method is not implemented for the NER task yet.
Are you guys working on it already?
+1 here
This issue has been automatically marked as stale because it has not had recent activity. It will be closed in 21 days if no further activity occurs.
Question Hi, I am currently fine-tuning a BERT-Model on a custom NER dataset. The classes are very imbalanced, so I tried to use the _calculate_classweights method on my data silo. Unfortunately I ran into errors and I am not really sure which "task_type" to set. My Script is based on this example with a few parameter adjustments for my dataset.
When I run the following code on the above example, I get a TypeError, as "task_type" is not set:
So I tried to add the "task_type" to the NERProcessor by doing this (not exactly sure which "task_type" to set):
I also tried to set the "task_type" to "multilabel" which results in a IndexError:
Which "task_type" do I have to set or am I doing something wrong in the code? Thank your for you help!
Additional context Add any other context or screenshots about the question (optional).