fc148e1a29e3d7893c438f701b8422225c95fc66,examples/classification.py,MNISTGenerator,create,#MNISTGenerator#,66
Before Change
ops.describe("custom_generator")
net = gan.inputs.x
net = ops.reshape(net, [gan.batch_size(), -1] )
net = ops.linear(net, end_features)
net = ops.lookup("tanh")(net)
self.fy = net
self.sample = net
return net
def layer(self, name):
return getattr(self, name)
After Change
class MNISTGenerator(BaseGenerator):
def create(self):
self.linear = torch.nn.Linear(28*28*1, 1024)
self.relu = torch.nn.ReLU()
self.linear2 = torch.nn.Linear(1024, 10)
self.sigmoid = torch.nn.Sigmoid()
def forward(self, input, context={}):
net = input
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 6
Instances Project Name: HyperGAN/HyperGAN
Commit Name: fc148e1a29e3d7893c438f701b8422225c95fc66
Time: 2020-07-10
Author: mikkel@255bits.com
File Name: examples/classification.py
Class Name: MNISTGenerator
Method Name: create
Project Name: facebookresearch/pytext
Commit Name: 33d79d35b6cebf156f226a3c4c83e2d7d1053599
Time: 2019-04-24
Author: snl@fb.com
File Name: pytext/models/embeddings/word_embedding.py
Class Name: WordEmbedding
Method Name: __init__
Project Name: mariogeiger/se3cnn
Commit Name: 5f3cddb62a332dc7d98dfacebf94d10bf7874600
Time: 2018-01-17
Author: geiger.mario@gmail.com
File Name: arch/example.py
Class Name: CNN
Method Name: __init__