Skip to content

Commit

Permalink
update test
Browse files Browse the repository at this point in the history
  • Loading branch information
KsenijaS committed Jan 28, 2021
1 parent d5a7c61 commit dd1d590
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions test/onnx/test_pytorch_onnx_onnxruntime.py
Original file line number Diff line number Diff line change
Expand Up @@ -2742,6 +2742,7 @@ def __init__(self):
self.register_buffer("weight", torch.ones(5))

def forward(self, x):
# shape is of rank 0
shape = self.weight.shape[0]
m = 5 - shape
return x.clamp(min=m)
Expand All @@ -2755,6 +2756,7 @@ def __init__(self):
self.register_buffer("weight", torch.ones(2))

def forward(self, x):
# shape is of rank 0
shape = self.weight.shape[0]
pad = [1, shape, shape, shape]
zero_pad = torch.nn.ZeroPad2d(pad)
Expand Down

0 comments on commit dd1d590

Please sign in to comment.