mindspore.train.F1
=====================

.. image:: https://mindspore-website.obs.cn-north-4.myhuaweicloud.com/website-images/r2.2/resource/_static/logo_source.svg
    :target: https://gitee.com/mindspore/mindspore/blob/r2.2/docs/api/api_python/train/mindspore.train.F1.rst
    :alt: 查看源文件


.. py:class:: mindspore.train.F1

    计算F1 score。F1是Fbeta的特殊情况,即beta为1。
    有关更多详细信息,请参阅类 :class:`mindspore.train.Fbeta`。

    .. math::
        F_1=\frac{2\cdot true\_positive}{2\cdot true\_positive + false\_negative + false\_positive}