8798ff3ea929027742519256709dc4664559a8cb,beginner_source/nn_tutorial.py,Mnist_Logistic,__init__,#Mnist_Logistic#,299

Before Change


class Mnist_Logistic(nn.Module):
    def __init__(self):
        super().__init__()
        self.weights = nn.Parameter(torch.randn(784, 10) / math.sqrt(784))
        self.bias = nn.Parameter(torch.zeros(10))

    def forward(self, xb):
        return xb @ self.weights + self.bias

After Change


class Mnist_Logistic(nn.Module):
    def __init__(self):
        super().__init__()
        self.lin = nn.Linear(784, 10)

    def forward(self, xb):
        return self.lin(xb)
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 9

Non-data size: 13

Instances


Project Name: pytorch/tutorials
Commit Name: 8798ff3ea929027742519256709dc4664559a8cb
Time: 2019-03-28
Author: brianjo@gmail.com
File Name: beginner_source/nn_tutorial.py
Class Name: Mnist_Logistic
Method Name: __init__


Project Name: pytorch/tutorials
Commit Name: 0bda28d38dad2325e26ab676ae3c1b9f6f2d5ee2
Time: 2019-02-08
Author: juan.cruz@ibm.com
File Name: beginner_source/nn_tutorial.py
Class Name: Mnist_Logistic
Method Name: __init__


Project Name: pytorch/tutorials
Commit Name: a42fb20c8be5c113321f710eb767f98d3264725c
Time: 2021-02-08
Author: SimonCW@users.noreply.github.com
File Name: beginner_source/nn_tutorial.py
Class Name: Mnist_Logistic
Method Name: __init__


Project Name: pytorch/tutorials
Commit Name: f754198e4b1ad99b11c87291fdc849a3d4732a49
Time: 2018-10-30
Author: brianjo@fb.com
File Name: beginner_source/nn_basics.py
Class Name: Mnist_Logistic
Method Name: __init__


Project Name: pytorch/tutorials
Commit Name: 7ee582ae3de041d6900abe972ddabc7b8a2ef2a1
Time: 2019-06-26
Author: willfeng@fb.com
File Name: beginner_source/nn_tutorial.py
Class Name: Mnist_Logistic
Method Name: __init__


Project Name: pytorch/tutorials
Commit Name: d87425afee537990691fe416d05ddfe88e5ebc03
Time: 2019-01-09
Author: joelm@fb.com
File Name: beginner_source/nn_tutorial.py
Class Name: Mnist_Logistic
Method Name: __init__


Project Name: pytorch/tutorials
Commit Name: bbb5f2bd48bb0f147366a761d0b2d7851bb0b7f4
Time: 2019-01-14
Author: brianjo@fb.com
File Name: beginner_source/nn_tutorial.py
Class Name: Mnist_Logistic
Method Name: __init__


Project Name: pytorch/tutorials
Commit Name: 18c62bdf1e3fe7ed0776751a097891111465e5e1
Time: 2019-06-26
Author: willfeng@fb.com
File Name: beginner_source/nn_tutorial.py
Class Name: Mnist_Logistic
Method Name: __init__


Project Name: pytorch/tutorials
Commit Name: 8798ff3ea929027742519256709dc4664559a8cb
Time: 2019-03-28
Author: brianjo@gmail.com
File Name: beginner_source/nn_tutorial.py
Class Name: Mnist_Logistic
Method Name: __init__


Project Name: pytorch/tutorials
Commit Name: 1fa08cbb00034b2af9e25720a99d11af70360bf8
Time: 2020-12-02
Author: brianjo@fb.com
File Name: beginner_source/nn_tutorial.py
Class Name: Mnist_Logistic
Method Name: __init__