acbb48c8695da72b55ad099bc84881dbb13a60bf,model.py,CapsuleGenerator,forward,#CapsuleGenerator#,29

Before Change


        x = self.lrelu(self.conv1(x))
        x = self.lrelu(self.conv2(x))

        x = self.conv3(x)
        // capsules squash
        x = torch.cat([squash(capsule) for capsule in torch.chunk(x, chunks=128, dim=1)], dim=1)
        x = self.conv4(x)
        x = torch.cat([squash(capsule) for capsule in torch.chunk(x, chunks=64, dim=1)], dim=1)
        x = self.conv5(x)
        x = torch.cat([squash(capsule) for capsule in torch.chunk(x, chunks=32, dim=1)], dim=1)
        x = self.conv6(x)

After Change


    def forward(self, x):
        x = self.lrelu(self.conv1(x))
        x = self.lrelu(self.conv2(x))
        x = self.lrelu(self.conv3(x))
        x = self.lrelu(self.conv4(x))
        x = self.lrelu(self.conv5(x))
        // capsules squash
        x = torch.cat([squash(capsule) for capsule in torch.chunk(x, chunks=8, dim=1)], dim=1)
        x = self.conv6(x)
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 2

Instances


Project Name: leftthomas/SRGAN
Commit Name: acbb48c8695da72b55ad099bc84881dbb13a60bf
Time: 2017-11-23
Author: leftthomas@qq.com
File Name: model.py
Class Name: CapsuleGenerator
Method Name: forward


Project Name: leftthomas/SRGAN
Commit Name: acbb48c8695da72b55ad099bc84881dbb13a60bf
Time: 2017-11-23
Author: leftthomas@qq.com
File Name: model.py
Class Name: CapsuleDiscriminator
Method Name: forward


Project Name: rusty1s/pytorch_geometric
Commit Name: a7fd67bd27f83cf7c9438626bb642e1928dbe814
Time: 2020-09-23
Author: matthias.fey@tu-dortmund.de
File Name: examples/ppi.py
Class Name: Net
Method Name: forward


Project Name: leftthomas/SRGAN
Commit Name: acbb48c8695da72b55ad099bc84881dbb13a60bf
Time: 2017-11-23
Author: leftthomas@qq.com
File Name: model.py
Class Name: CapsuleGenerator
Method Name: forward