模型:
DeepPavlov/distilrubert-small-cased-conversational
Conversational DistilRuBERT-smalldistilrubert-small-cased-conversational(俄语,有大小写,2层,768隐藏层,12个注意头,107M个参数)在OpenSubtitles[1]、 Dirty 、 Pikabu 和Taiga语料库的社交媒体部分[2](作为 Conversational RuBERT )上进行了训练。它可以被视为 Conversational DistilRuBERT-base 的小版本。
我们的DistilRuBERT-small深受[3]、[4]的启发。具体而言,我们使用了以下内容:
该模型经过了大约80小时的训练,使用了8个nVIDIA Tesla P100-SXM2.0 16Gb。
为了评估推理速度的改进,我们对随机序列上的老师和学生模型进行了测试,序列长度为512,batch_size为16(用于吞吐量)和batch_size为1(用于延迟)。所有测试都在Intel(R) Xeon(R) CPU E5-2698 v4 @ 2.20GHz和nVIDIA Tesla P100-SXM2.0 16Gb上执行。
Model | Size, Mb. | CPU latency, sec. | GPU latency, sec. | CPU throughput, samples/sec. | GPU throughput, samples/sec. |
---|---|---|---|---|---|
Teacher (RuBERT-base-cased-conversational) | 679 | 0.655 | 0.031 | 0.3754 | 36.4902 |
Student (DistilRuBERT-small-cased-conversational) | 409 | 0.1656 | 0.015 | 0.9692 | 71.3553 |
为了评估模型的质量,我们在分类、NER和问答任务上对DistilRuBERT-small进行了微调。得分和微调模型的存档可以在 DeepPavlov docs 中找到。此外,结果也可以在 paper 的表格1&2中找到,以及性能基准和训练细节。
如果您发现该模型对您的研究有用,请引用 this 论文:
@misc{https://doi.org/10.48550/arxiv.2205.02340, doi = {10.48550/ARXIV.2205.02340}, url = {https://arxiv.org/abs/2205.02340}, author = {Kolesnikova, Alina and Kuratov, Yuri and Konovalov, Vasily and Burtsev, Mikhail}, keywords = {Computation and Language (cs.CL), Machine Learning (cs.LG), FOS: Computer and information sciences, FOS: Computer and information sciences}, title = {Knowledge Distillation of Russian Language Models with Reduction of Vocabulary}, publisher = {arXiv}, year = {2022}, copyright = {arXiv.org perpetual, non-exclusive license} }
[1]: P. Lison and J. Tiedemann, 2016, OpenSubtitles2016: Extracting Large Parallel Corpora from Movie and TV Subtitles. In Proceedings of the 10th International Conference on Language Resources and Evaluation (LREC 2016)
[2]: Shavrina T., Shapovalova O. (2017) TO THE METHODOLOGY OF CORPUS CONSTRUCTION FOR MACHINE LEARNING: «TAIGA» SYNTAX TREE CORPUS AND PARSER. in proc. of “CORPORA2017”, international conference , Saint-Petersbourg, 2017.
[3]: Sanh, V., Debut, L., Chaumond, J., & Wolf, T. (2019). DistilBERT, a distilled version of BERT: smaller, faster, cheaper and lighter. arXiv preprint arXiv:1910.01108.
[4]: https://github.com/huggingface/transformers/tree/master/examples/research_projects/distillation