categorical.py 文件源码

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

项目:third_person_im 作者: bstadie 项目源码 文件源码
def __init__(self, dim):
        self._dim = dim
        weights_var = tf.placeholder(
            dtype=tf.float32,
            shape=(None, dim),
            name="weights"
        )
        self._f_sample = tensor_utils.compile_function(
            inputs=[weights_var],
            outputs=tf.multinomial(weights_var, num_samples=1)[:, 0],
        )
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号