Skip to content

Commit

Permalink
#2 Fix broadcasting issue in FQ ref implementation
Browse files Browse the repository at this point in the history
  • Loading branch information
vurusovs committed Apr 14, 2023
1 parent 934793c commit 259b4c1
Showing 1 changed file with 1 addition and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,7 @@ inline std::vector<size_t> calc_broadcast_index_offset(const std::vector<size_t>
const std::vector<size_t>& broadcast_shape) {
std::vector<size_t> broadcast_offsets(broadcast_shape.size(), 0);
for (int i = static_cast<int>(broadcast_shape.size()) - 2; i >= 0; --i) {
if (broadcast_shape[i] == 1) {
broadcast_offsets[i] = memory_offsets[i];
}
broadcast_offsets[i] = memory_offsets[i];
}
const auto not_one = [](size_t i) {
return i != 1;
Expand Down

0 comments on commit 259b4c1

Please sign in to comment.