2179685be9f876bc33362d0c680dbd68c3c4de0a,bindsnet/learning/learning.py,PostPre,_connection_update,#PostPre#,172

Before Change



        // Pre-synaptic update.
        if self.nu[0]:
            update = self.reduction(torch.bmm(source_s, target_x), dim=0)
            self.connection.w -= self.nu[0] * update

        // Post-synaptic update.
        if self.nu[1]:

After Change


        if self.nu[0]:
            source_s = self.source.s.view(batch_size, -1).unsqueeze(2).float()
            target_x = self.target.x.view(batch_size, -1).unsqueeze(1) * self.nu[0]
            self.connection.w -= self.reduction(torch.bmm(source_s, target_x), dim=0)
            del source_s, target_x

        // Post-synaptic update.
        if self.nu[1]:
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 3

Instances


Project Name: BindsNET/bindsnet
Commit Name: 2179685be9f876bc33362d0c680dbd68c3c4de0a
Time: 2020-11-16
Author: simoncaby28@gmail
File Name: bindsnet/learning/learning.py
Class Name: PostPre
Method Name: _connection_update


Project Name: scipy/scipy
Commit Name: 69b6ba7d0db7b91aa29e0cc647f2c43ddc4e34fc
Time: 2014-02-16
Author: ralf.gommers@googlemail.com
File Name: scipy/weave/tests/test_size_check.py
Class Name: TestReduction
Method Name: test_error1


Project Name: scipy/scipy
Commit Name: 69b6ba7d0db7b91aa29e0cc647f2c43ddc4e34fc
Time: 2014-02-16
Author: ralf.gommers@googlemail.com
File Name: scipy/weave/tests/test_size_check.py
Class Name: TestReduction
Method Name: test_error0