Skip to content

Commit

Permalink
Apply suggestions from code review
Browse files Browse the repository at this point in the history
Co-authored-by: fritzgoebel <[email protected]>
  • Loading branch information
yhmtsai and fritzgoebel authored Sep 11, 2020
1 parent 3ae2b45 commit acaa457
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 4 deletions.
2 changes: 1 addition & 1 deletion common/matrix/dense_kernels.hpp.inc
Original file line number Diff line number Diff line change
Expand Up @@ -534,7 +534,7 @@ __global__ __launch_bounds__(default_block_size) void outplace_absolute_dense(
auto row = tidx / num_cols;
auto col = tidx % num_cols;
if (row < num_rows) {
out[row * stride_out + col] = abs(in[row * stride_out + col]);
out[row * stride_out + col] = abs(in[row * stride_in + col]);
}
}

Expand Down
1 change: 1 addition & 0 deletions core/matrix/csr.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,7 @@ GKO_REGISTER_OPERATION(inplace_absolute_array,
GKO_REGISTER_OPERATION(outplace_absolute_array,
components::outplace_absolute_array);


} // namespace csr


Expand Down
1 change: 1 addition & 0 deletions core/test/base/lin_op.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include <ginkgo/core/base/lin_op.hpp>
#include <ginkgo/core/base/math.hpp>


#include <gtest/gtest.h>


Expand Down
2 changes: 1 addition & 1 deletion include/ginkgo/core/base/lin_op.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -625,7 +625,7 @@ class DiagonalExtractable {


/**
* The AbsoluteComputable is an interface to allow get absolute from a LinOp.
* The AbsoluteComputable is an interface that allows to get the component wise absolute of a LinOp.
* Use EnableAbsoluteComputation<ConcreteLinOp> to implement this interface.
*/
class AbsoluteComputable {
Expand Down
4 changes: 2 additions & 2 deletions reference/test/components/absolute_array.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ class AbsoluteArray : public ::testing::Test {
TYPED_TEST_CASE(AbsoluteArray, gko::test::ValueTypes);


TYPED_TEST(AbsoluteArray, InplaceEqualsReference)
TYPED_TEST(AbsoluteArray, InplaceEqualsExpected)
{
using T = typename TestFixture::value_type;
gko::kernels::reference::components::inplace_absolute_array(
Expand All @@ -87,7 +87,7 @@ TYPED_TEST(AbsoluteArray, InplaceEqualsReference)
}


TYPED_TEST(AbsoluteArray, OutplaceEqualsReference)
TYPED_TEST(AbsoluteArray, OutplaceEqualsExpected)
{
using T = typename TestFixture::value_type;
using AbsT = typename TestFixture::abs_type;
Expand Down

0 comments on commit acaa457

Please sign in to comment.