Skip to content

Commit 377ad67

Browse files
committed
fix(//core/conversion/converters/impl/linear): In inserting flatten for
layers other than conv, did not remove batch size from tensor shape Signed-off-by: Naren Dasan <[email protected]> Signed-off-by: Naren Dasan <[email protected]>
1 parent 36b2eb4 commit 377ad67

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

core/conversion/converters/impl/linear.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ auto linear_registrations = RegisterNodeConversionPatterns()
2727
new_shape.push_back(shape[0]);
2828
new_shape.push_back(1);
2929
new_shape.push_back(1);
30-
new_shape.push_back(util::volume(util::toDims(shape)));
30+
new_shape.push_back(util::volume(util::toDims(shape)) / shape[0]);
3131

3232
auto new_dims = util::toDims(new_shape);
3333
LOG_DEBUG("Input shape is less than 4D got: " << util::toDims(shape) << ", inserting shuffle layer to reshape to 4D tensor shape: " << new_dims);

0 commit comments

Comments
 (0)