ad0437cbe8b274d5268914718cf036efe5f4b772,hypergan/graph/graph.py,Graph,create_z_encoding,#Graph#,64

Before Change


        return [d_real, d_fake, d_reals, d_fakes]

    def create_z_encoding(self):
        z_base_config = hc.Config(hc.lookup_functions(self.gan.config.z_encoder_base))
        self.gan.graph.z_base = z_base_config.create(z_base_config, self.gan)
        encoders = [self.gan.graph.z_base]
        for i, encoder in enumerate(self.gan.config.z_encoders):
            encoder = hc.Config(hc.lookup_functions(encoder))

After Change


        return [d_real, d_fake, d_reals, d_fakes]

    def create_z_encoding(self):
        self.gan.graph.z = []
        encoders = []
        for i, encoder in enumerate(self.gan.config.encoders):
            encoder = hc.Config(hc.lookup_functions(encoder))
            zs, z_base = encoder.create(encoder, self.gan)
            encoders.append(zs)
            self.gan.graph.z.append(z_base)

        z_encoded = tf.concat(1, encoders)
        self.gan.graph.z_encoded = z_encoded
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 4

Instances


Project Name: HyperGAN/HyperGAN
Commit Name: ad0437cbe8b274d5268914718cf036efe5f4b772
Time: 2017-02-13
Author: mikkel@255bits.com
File Name: hypergan/graph/graph.py
Class Name: Graph
Method Name: create_z_encoding


Project Name: pantsbuild/pants
Commit Name: cf6f30685b1540ae99c8ab7dd23ee4e75e5d2275
Time: 2014-12-08
Author: benjyw@gmail.com
File Name: src/python/pants/base/config.py
Class Name: Config
Method Name: load


Project Name: HyperGAN/HyperGAN
Commit Name: 5a949f8810dbc838c5827928bdcd83f65876a955
Time: 2017-02-13
Author: mikkel@255bits.com
File Name: hypergan/graph/graph.py
Class Name: Graph
Method Name: create_z_encoding