mirror of
https://github.com/pytorch/pytorch.git
synced 2025-10-20 21:14:14 +08:00
Summary: Original commit changeset: 81319beb97f3 Original Phabricator Diff: D47961182 Test Plan: revert to maintain backward compat with legacy ads_dper3 production package. Read details in: S357822 Reviewed By: atuljangra Differential Revision: D48131623 @diff-train-skip-merge (D48131623 landed internally) Pull Request resolved: https://github.com/pytorch/pytorch/pull/106743 Approved by: https://github.com/malfet
This commit is contained in:
committed by
PyTorch MergeBot
parent
891bb259f8
commit
bc88028e8e
@ -1248,8 +1248,8 @@ class {test_classname}(torch.nn.Module):
|
||||
self.seq = torch.nn.Sequential(torch.nn.BatchNorm1d(2, 2))
|
||||
self.linear = torch.nn.Linear(2, 2)
|
||||
self.attr = torch.randn(2)
|
||||
self.attr2 = torch.nn.Buffer(torch.randn(2))
|
||||
self.attr3 = torch.nn.Buffer(torch.ones(2, dtype=torch.int32))
|
||||
self.register_buffer("attr2", torch.randn(2))
|
||||
self.register_buffer("attr3", torch.ones(2, dtype=torch.int32))
|
||||
|
||||
def forward(self, x):
|
||||
return self.linear(self.seq(self.W + self.attr + self.attr2 + self.attr3 + x))
|
||||
|
||||
Reference in New Issue
Block a user