Skip to content

Commit 77f6d41

Browse files
committed
Add check for multiples parameter of TileND
1 parent 568e059 commit 77f6d41

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/caffe/layers/tile_nd_layer.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,10 @@ void TileNDLayer<Dtype>::LayerSetUp(
1414
tile_nd_param.multiples().end(),
1515
std::back_inserter(multiples_));
1616

17-
CHECK_GT(multiples_.size(), 0) << "Number of tiles must be positive!";
17+
CHECK_EQ(multiples_.size(), bottom[0]->num_axes()) << "Length must be the same as the number of dimensions in input!";
1818
for(int i=0;i<multiples_.size();i++)
1919
{
20-
CHECK_GT(multiples_[i], 0) << "Value of tiles must be positive!";
20+
CHECK_GT(multiples_[i], 0) << "Value of multiples must be positive!";
2121
}
2222
}
2323

0 commit comments

Comments
 (0)