multiclass_svm.py 文件源码

python
阅读 32 收藏 0 点赞 0 评论 0

项目:TensorFlow-World 作者: astorfi 项目源码 文件源码
def kernel_pred(x_data, prediction_grid):
    A = tf.reshape(tf.reduce_sum(tf.square(x_data), 1), [-1, 1])
    B = tf.reshape(tf.reduce_sum(tf.square(prediction_grid), 1), [-1, 1])
    square_distance = tf.add(tf.subtract(A, tf.multiply(2., tf.matmul(x_data, tf.transpose(prediction_grid)))),
                             tf.transpose(B))
    return tf.exp(tf.multiply(gamma, tf.abs(square_distance)))
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号