Skip to content
This repository has been archived by the owner on Sep 1, 2023. It is now read-only.

Commit

Permalink
fix accumulate
Browse files Browse the repository at this point in the history
  • Loading branch information
suzusuzu committed Mar 22, 2018
1 parent b810382 commit e5e48c8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/nupic/algorithms/SDRClassifier.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -238,7 +238,7 @@ void SDRClassifier::softmax_(Iterator begin, Iterator end) {
}
range_exp(1.0, begin, end);
typename std::iterator_traits<Iterator>::value_type sum =
accumulate(begin, end, 0);
accumulate(begin, end, 0.0);
for (auto itr = begin; itr != end; ++itr) {
*itr /= sum;
}
Expand Down

0 comments on commit e5e48c8

Please sign in to comment.