1 #include "../../../include/common/monolish_dense.hpp"
2 #include "../../../include/common/monolish_logger.hpp"
3 #include "../../../include/common/monolish_matrix.hpp"
4 #include "../../internal/monolish_internal.hpp"
21 if (get_device_mem_stat() ==
true && force_cpu ==
false) {
23 const T *vald = val.data();
25 for (
size_t i = 0; i < get_row(); i++) {
26 for (
size_t j = 0; j < get_col(); j++) {
27 printf(
"%lu %lu %f\n", i + 1, j + 1, vald[i * get_col() + j]);
31 throw std::runtime_error(
32 "error USE_GPU is false, but get_device_mem_stat() == true");
35 for (
size_t i = 0; i < get_row(); i++) {
36 for (
size_t j = 0; j < get_col(); j++) {
37 std::cout << i + 1 <<
" " << j + 1 <<
" " << val[i * get_col() + j]