📜  交叉熵 - Python 代码示例

📅  最后修改于: 2022-03-11 14:45:17.578000             🧑  作者: Mango

代码示例1
class QuadraticCost(object):

    @staticmethod
    def fn(a, y):
        return 0.5*np.linalg.norm(a-y)**2

    @staticmethod
    def delta(z, a, y):
        return (a-y) * sigmoid_prime(z)