You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello, I am training a udify model only for Korean where I train only on the Korean data from UD2.3. However, I am running into the following issue. The same code runs fine on other languages from UD.
Traceback (most recent call last):
File "train.py", line 113, in
train_model(train_params, serialization_dir, recover=bool(args.resume))
File "/home/user/anaconda3/envs/dependency_parse/lib/python3.7/site-packages/allennlp/commands/train.py", line 226, in train_model
cache_prefix)
File "/home/user/anaconda3/envs/dependency_parse/lib/python3.7/site-packages/allennlp/training/trainer_pieces.py", line 65, in from_params
model = Model.from_params(vocab=vocab, params=params.pop('model'))
File "/home/user/anaconda3/envs/dependency_parse/lib/python3.7/site-packages/allennlp/common/from_params.py", line 365, in from_params
return subclass.from_params(params=params, **extras)
File "/home/user/anaconda3/envs/dependency_parse/lib/python3.7/site-packages/allennlp/common/from_params.py", line 386, in from_params
kwargs = create_kwargs(cls, params, **extras)
File "/home/user/anaconda3/envs/dependency_parse/lib/python3.7/site-packages/allennlp/common/from_params.py", line 133, in create_kwargs
kwargs[name] = construct_arg(cls, name, annotation, param.default, params, **extras)
File "/home/user/anaconda3/envs/dependency_parse/lib/python3.7/site-packages/allennlp/common/from_params.py", line 257, in construct_arg
value_dict[key] = value_cls.from_params(params=value_params, **subextras)
File "/home/user/anaconda3/envs/dependency_parse/lib/python3.7/site-packages/allennlp/common/from_params.py", line 365, in from_params
return subclass.from_params(params=params, **extras)
File "/home/user/anaconda3/envs/dependency_parse/lib/python3.7/site-packages/allennlp/common/from_params.py", line 388, in from_params
return cls(**kwargs) # type: ignore
File "/home/user/udify-master/udify/models/tag_decoder.py", line 105, in init
div_value=4.0)
File "/home/user/anaconda3/envs/dependency_parse/lib/python3.7/site-packages/torch/nn/modules/adaptive.py", line 133, in init
raise ValueError("cutoffs should be a sequence of unique, positive "
ValueError: cutoffs should be a sequence of unique, positive integers sorted in an increasing order, where each value is between 1 and n_classes-1
The text was updated successfully, but these errors were encountered:
Hi,
I am facing the exact same problem with the following languages: Hindi, Thai, Chinese and Japanese. Have you been able to solve your issue? If so, could you please share the solution?
Thank you in advance.
Hello, I encountered the same error with the languages Chinese and Japanese, I found that in udify/models/tag_decoder.py, the adaptive_cutoffs I got was [0,0] that caused the issue. So I change self.adaptive as false if the self.num_classes is small, it seems that this solves my problem.
Hello, I am training a udify model only for Korean where I train only on the Korean data from UD2.3. However, I am running into the following issue. The same code runs fine on other languages from UD.
Traceback (most recent call last):
File "train.py", line 113, in
train_model(train_params, serialization_dir, recover=bool(args.resume))
File "/home/user/anaconda3/envs/dependency_parse/lib/python3.7/site-packages/allennlp/commands/train.py", line 226, in train_model
cache_prefix)
File "/home/user/anaconda3/envs/dependency_parse/lib/python3.7/site-packages/allennlp/training/trainer_pieces.py", line 65, in from_params
model = Model.from_params(vocab=vocab, params=params.pop('model'))
File "/home/user/anaconda3/envs/dependency_parse/lib/python3.7/site-packages/allennlp/common/from_params.py", line 365, in from_params
return subclass.from_params(params=params, **extras)
File "/home/user/anaconda3/envs/dependency_parse/lib/python3.7/site-packages/allennlp/common/from_params.py", line 386, in from_params
kwargs = create_kwargs(cls, params, **extras)
File "/home/user/anaconda3/envs/dependency_parse/lib/python3.7/site-packages/allennlp/common/from_params.py", line 133, in create_kwargs
kwargs[name] = construct_arg(cls, name, annotation, param.default, params, **extras)
File "/home/user/anaconda3/envs/dependency_parse/lib/python3.7/site-packages/allennlp/common/from_params.py", line 257, in construct_arg
value_dict[key] = value_cls.from_params(params=value_params, **subextras)
File "/home/user/anaconda3/envs/dependency_parse/lib/python3.7/site-packages/allennlp/common/from_params.py", line 365, in from_params
return subclass.from_params(params=params, **extras)
File "/home/user/anaconda3/envs/dependency_parse/lib/python3.7/site-packages/allennlp/common/from_params.py", line 388, in from_params
return cls(**kwargs) # type: ignore
File "/home/user/udify-master/udify/models/tag_decoder.py", line 105, in init
div_value=4.0)
File "/home/user/anaconda3/envs/dependency_parse/lib/python3.7/site-packages/torch/nn/modules/adaptive.py", line 133, in init
raise ValueError("cutoffs should be a sequence of unique, positive "
ValueError: cutoffs should be a sequence of unique, positive integers sorted in an increasing order, where each value is between 1 and n_classes-1
The text was updated successfully, but these errors were encountered: