Skip to content

Commit

Permalink
Fix wrong index in LogPlusOne
Browse files Browse the repository at this point in the history
  • Loading branch information
vinx13 authored and vigsterkr committed May 30, 2018
1 parent 801633c commit b383892
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/shogun/preprocessor/LogPlusOne.cpp
Expand Up @@ -45,9 +45,9 @@ bool CLogPlusOne::save(FILE* f)

SGMatrix<float64_t> CLogPlusOne::apply_to_matrix(SGMatrix<float64_t> matrix)
{
for (auto i : range(matrix.num_cols))
for (auto j : range(matrix.num_cols))
{
for (auto j : range(matrix.num_rows))
for (auto i : range(matrix.num_rows))
matrix(i, j) = std::log(matrix(i, j) + 1.0);
}
return matrix;
Expand Down

0 comments on commit b383892

Please sign in to comment.