Code Monkey home page Code Monkey logo

Comments (7)

Tongjilibo avatar Tongjilibo commented on June 15, 2024

想问下这个小数点是指哪里的小数点啊

from bert4torch.

Tongjilibo avatar Tongjilibo commented on June 15, 2024

我看了下,可以在脚本最开始使用如下代码实现,默认为4

import os
os.environ['ROUND_PRECISION'] = '4'

from bert4torch.

xinjiesun-ustc avatar xinjiesun-ustc commented on June 15, 2024
  • Finish Training 这个结果只有两位小数,怎么保留四位呢??

from bert4torch.

Tongjilibo avatar Tongjilibo commented on June 15, 2024
  • Finish Training 这个结果只有两位小数,怎么保留四位呢??

不好意思,没太理解你的意思,你如果说的是评估evaluate时候的指标精度,那是用户自行控制的,和框架自身无关

from bert4torch.

xinjiesun-ustc avatar xinjiesun-ustc commented on June 15, 2024

比如说某数据集的训练或者测试的结果,精度都是两位 ,原始显示格式如下:

precision recall f1-score support

       0       0.74      0.78      0.76       173
       1       0.79      0.79      0.79       346
       2       0.75      0.69      0.72       173

accuracy                           0.76       692

macro avg 0.76 0.75 0.76 692
weighted avg 0.76 0.76 0.76 692

如何在classification.py进行修改精度,我没有找到修改精度的地方,应该是我的问题,如果可以请指明一下如何修改吗;另外weighted avg 这个是应该是加权平均的意思,它和 accuracy的区别是?如何设置的权重呢?

from bert4torch.

Tongjilibo avatar Tongjilibo commented on June 15, 2024

你说的是sklearn.metrics中的classification_report函数这些吧,建议进去函数内部查一下函数的参数,比如classification_report有一个digit参数之类

from bert4torch.

xinjiesun-ustc avatar xinjiesun-ustc commented on June 15, 2024

非常感谢,明白了!确实是修改digit就可以了!

from bert4torch.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.