gvae.py 文件源码

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

项目:Gumbel-Softmax-VAE-in-tensorflow 作者: JeremyCCHsu 项目源码 文件源码
def __init__(self, arch, is_training=False):
        self.arch = arch
        self._sanity_check()
        self.is_training = is_training

        with tf.name_scope('SpeakerRepr'):        
            self.y_emb = self._unit_embedding(
                self.arch['y_dim'],
                self.arch['z_dim'],
                'y_embedding')

        with tf.variable_scope('Tau'):
            self.tau = tf.nn.relu(
                10. * tf.Variable(
                    tf.ones([1]),
                    name='tau')) + 0.1

        self._generate = tf.make_template(
            'Generator',
            self._generator)
        self._discriminate = tf.make_template(
            'Discriminator',
            self._discriminator)
        self._encode = tf.make_template(
            'Encoder',
            self._encoder)
        self._classify = tf.make_template(
            'Classifier',
            self._classifier)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号