I am using this config file
DeepPavlov/rusentiment_convers_bert.json at master · deepmipt/DeepPavlov · GitHub
with a slight change to solve a multi-class classification problem. First time I trained this model, my model turned out to be overfitted, so now I add some changes as below:
"weight_decay_rate": 0.001,
"learning_rate_drop_patience": 1,
"learning_rate_drop_div": 2.0,
"load_before_drop": True,
"min_learning_rate": 1e-03,
"attention_probs_keep_prob": 0.5,
"hidden_keep_prob": 0.5,
also, I increased the batch size, it was 16 before now:
"batch_size": 32
and added some metrics:
"log_loss",
"matthews_correlation",
Also changed validation_patience to 1 and added tensorboard func
"validation_patience": 1,
"tensorboard_log_dir": "logs/",
and these are all the changes I made to my model, and when i tried to train my model, it is giving me following error:
UFuncTypeError Traceback (most recent call last)
/usr/local/lib/python3.7/dist-packages/numpy/core/fromnumeric.py in _wrapfunc(obj, method, *args, **kwds)
60 try:
---> 61 return bound(*args, **kwds)
62 except TypeError:
15 frames
UFuncTypeError: ufunc 'clip' did not contain a loop with signature matching types (dtype('<U32'), dtype('<U32'), dtype('<U32')) -> dtype('<U32')
During handling of the above exception, another exception occurred:
UFuncTypeError Traceback (most recent call last)
<__array_function__ internals> in clip(*args, **kwargs)
/usr/local/lib/python3.7/dist-packages/numpy/core/_methods.py in _clip_dep_invoke_with_casting(ufunc, out, casting, *args, **kwargs)
83 # try to deal with broken casting rules
84 try:
---> 85 return ufunc(*args, out=out, **kwargs)
86 except _exceptions._UFuncOutputCastingError as e:
87 # Numpy 1.17.0, 2019-02-24
UFuncTypeError: ufunc 'clip' did not contain a loop with signature matching types (dtype('<U32'), dtype('<U32'), dtype('<U32')) -> dtype('<U32')
At first, I thought it has something to do with a dataset, however, i did not change my dataset and it has run the first time I trained this model.
Feel free to answer in any language you prefer (maybe Russian) if it will make it faster for you to answer, Thank you