Closed NovemberSun closed 3 years ago
从你的指令和结果来看,你漏了加载预训练模型参数:--pretrained_model_path ./models/google_model.bin
完整指令如下:
CUDA_VISIBLE_DEVICES='0' nohup python3 -u run_kbert_cls.py \ --pretrained_model_path ./models/google_model.bin \ --config_path ./models/google_config.json \ --vocab_path ./models/google_vocab.txt \ --train_path ./datasets/book_review/train.tsv \ --dev_path ./datasets/book_review/dev.tsv \ --test_path ./datasets/book_review/test.tsv \ --epochs_num 5 --batch_size 32 --kg_name CnDbpedia \ --output_model_path ./outputs/kbert_bookreview_CnDbpedia.bin \
./outputs/kbert_bookreview_CnDbpedia.log &
是的,谢谢!
您好,感谢您开源代码,我使用您的代码和您分享的book_review数据集进行试验,但是准确率只有79%,比您的结果低了快10个百分点。想问问您有没有什么建议呢? 我的运行指令为:nohup python3 -u run_kbert_cls.py --train_path /data/book_review/train.tsv --dev_path /data/book_review/dev.tsv --test_path /data/book_review/test.tsv --epochs_num 5 --batch_size 32 --kg_name CnDbpedia --output_model_path ./outputs/kbert_bookreview_CnDbpedia.bin > ./outputs/kbert_bookreview_CnDbpedia.log & (谷歌预训练模型和词表等文件路径我在程序中指定,max_length是默认的256) 我的结果为:79%![image](https://user-images.githubusercontent.com/32707117/92595966-a5b1ba00-f2d7-11ea-8dca-1b727933314f.png)