357d1611c7a222b55a5b4f2b3399bde14a9ac0ea,tgen/nn.py,MaxPool1DLayer,connect,#MaxPool1DLayer#Any#,167
Before Change
def connect(self, inputs):
if self.stride > 1:
output = T.max(T.reshape(inputs,
(inputs.shape[0] / self.stride,
inputs.shape[1] * self.stride)),
axis=0)
else:
output = T.max(inputs, axis=0)
self.inputs.append(inputs)
self.outputs.append(output)
After Change
// output = T.max(inputs, axis=0)
input_padded = T.shape_padright(inputs.dimshuffle(1, 0), 1)
// do the max-pooling
pooled = downsample.max_pool_2d(input_padded, (self.downscale_factor, 1), False)
// remove the padded dimension + swap dimensions back
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 5
Instances
Project Name: UFAL-DSG/tgen
Commit Name: 357d1611c7a222b55a5b4f2b3399bde14a9ac0ea
Time: 2015-05-27
Author: odusek@ufal.mff.cuni.cz
File Name: tgen/nn.py
Class Name: MaxPool1DLayer
Method Name: connect
Project Name: UFAL-DSG/tgen
Commit Name: 357d1611c7a222b55a5b4f2b3399bde14a9ac0ea
Time: 2015-05-27
Author: odusek@ufal.mff.cuni.cz
File Name: tgen/nn.py
Class Name: MaxPool1DLayer
Method Name: connect
Project Name: rodluger/starry
Commit Name: d5b179c50c764bcd37aa5348761e272170f9015f
Time: 2019-10-01
Author: rodluger@gmail.com
File Name: starry/ops/ops.py
Class Name: OpsReflected
Method Name: render
Project Name: UFAL-DSG/tgen
Commit Name: 930f22933523259b1a152dc3174312357fb99fb9
Time: 2015-06-15
Author: odusek@ufal.mff.cuni.cz
File Name: tgen/nn.py
Class Name: MaxPool1DLayer
Method Name: connect