Searched defs:num_nonzeros (Results 1 - 15 of 15) sorted by relevance

/external/ceres-solver/internal/ceres/
H A Dblock_random_access_diagonal_matrix_test.cc48 const int num_nonzeros = 3 * 3 + 4 * 4 + 5 * 5; local
88 EXPECT_EQ(tsm->num_nonzeros(), num_nonzeros);
89 EXPECT_EQ(tsm->max_num_nonzeros(), num_nonzeros);
H A Dblock_sparse_matrix.h80 virtual int num_nonzeros() const { return num_nonzeros_; } function in class:ceres::internal::BlockSparseMatrix
H A Dblock_random_access_diagonal_matrix.cc53 int num_nonzeros = 0; local
58 num_nonzeros += blocks_[i] * blocks_[i];
63 << "] " << num_nonzeros; local
65 tsm_.reset(new TripletSparseMatrix(num_cols, num_cols, num_nonzeros));
66 tsm_->set_num_nonzeros(num_nonzeros);
113 if (tsm_->num_nonzeros()) {
115 tsm_->num_nonzeros()).setZero();
H A Dblock_random_access_sparse_matrix.cc66 int num_nonzeros = 0; local
72 num_nonzeros += row_block_size * col_block_size;
77 << "] " << num_nonzeros; local
79 tsm_.reset(new TripletSparseMatrix(num_cols, num_cols, num_nonzeros));
80 tsm_->set_num_nonzeros(num_nonzeros);
151 if (tsm_->num_nonzeros()) {
153 tsm_->num_nonzeros()).setZero();
H A Dblock_random_access_sparse_matrix_test.cc49 int num_nonzeros = 0; local
51 num_nonzeros += blocks[0] * blocks[0];
54 num_nonzeros += blocks[1] * blocks[1];
57 num_nonzeros += blocks[1] * blocks[2];
60 num_nonzeros += blocks[2] * blocks[0];
92 EXPECT_EQ(tsm->num_nonzeros(), num_nonzeros);
93 EXPECT_EQ(tsm->max_num_nonzeros(), num_nonzeros);
H A Dcompressed_row_sparse_matrix.h91 virtual int num_nonzeros() const { return rows_[num_rows_]; } function in class:ceres::internal::CompressedRowSparseMatrix
119 void SetMaxNumNonZeros(int num_nonzeros);
H A Ddense_sparse_matrix.cc70 int num_nonzeros = m.num_nonzeros(); local
72 for (int i = 0; i < num_nonzeros; ++i) {
140 int DenseSparseMatrix::num_nonzeros() const { function in class:ceres::internal::DenseSparseMatrix
H A Dtriplet_sparse_matrix.h66 virtual int num_nonzeros() const { return num_nonzeros_; } function in class:ceres::internal::TripletSparseMatrix
69 virtual void set_num_nonzeros(int num_nonzeros);
H A Ddynamic_compressed_row_sparse_matrix_test.cc73 int num_nonzeros = 0; local
78 ++num_nonzeros;
81 ASSERT_EQ(num_nonzeros, expected_num_nonzeros);
129 EXPECT_EQ(dcrsm->num_nonzeros(), 0);
151 ConstIntVectorRef crsm_cols(crsm->cols(), crsm->num_nonzeros());
152 ConstIntVectorRef dcrsm_cols(dcrsm->cols(), dcrsm->num_nonzeros());
155 ConstVectorRef crsm_values(crsm->values(), crsm->num_nonzeros());
156 ConstVectorRef dcrsm_values(dcrsm->values(), dcrsm->num_nonzeros());
H A Dincomplete_lq_factorization.cc122 int num_nonzeros = rows[matrix->num_rows()]; local
126 rows[matrix->num_rows()] = num_nonzeros;
154 cols[num_nonzeros] = entry.first;
155 values[num_nonzeros] = entry.second;
156 ++num_nonzeros;
160 rows[matrix->num_rows()] = num_nonzeros;
230 l_cols[l->num_nonzeros()] = i;
231 l_values[l->num_nonzeros()] = NormalizeRow(i, &q);
H A Dtriplet_sparse_matrix.cc135 void TripletSparseMatrix::set_num_nonzeros(int num_nonzeros) { argument
136 CHECK_GE(num_nonzeros, 0);
137 CHECK_LE(num_nonzeros, max_num_nonzeros_);
138 num_nonzeros_ = num_nonzeros;
H A Dcompressed_row_sparse_matrix.cc96 cols_.resize(m.num_nonzeros(), 0);
100 vector<int> index(m.num_nonzeros(), 0);
101 for (int i = 0; i < m.num_nonzeros(); ++i) {
119 for (int i = 0; i < m.num_nonzeros(); ++i) {
131 CHECK_EQ(num_nonzeros(), m.num_nonzeros());
151 CHECK_EQ(num_nonzeros(), num_rows);
241 if (cols_.size() < num_nonzeros() + m.num_nonzeros()) {
242 cols_.resize(num_nonzeros()
289 SetMaxNumNonZeros(int num_nonzeros) argument
320 int num_nonzeros = 0; local
425 int num_nonzeros = 1; local
[all...]
H A Dcompressed_row_sparse_matrix_test.cc224 EXPECT_EQ(crsm->num_nonzeros(), crs_matrix.cols.size());
225 EXPECT_EQ(crsm->num_nonzeros(), crs_matrix.values.size());
231 for (int i = 0; i < crsm->num_nonzeros(); ++i) {
254 EXPECT_EQ(matrix->num_nonzeros(), 9);
463 const int num_nonzeros = values.size(); local
465 TripletSparseMatrix tsm(num_rows, num_cols, num_nonzeros);
469 tsm.set_num_nonzeros(num_nonzeros);
H A Dprogram.cc391 int num_nonzeros = 0; local
408 if (num_nonzeros >= tsm->max_num_nonzeros()) {
409 tsm->set_num_nonzeros(num_nonzeros);
410 tsm->Reserve(2 * num_nonzeros);
417 rows[num_nonzeros] = r;
418 cols[num_nonzeros] = c;
419 values[num_nonzeros] = 1.0;
420 ++num_nonzeros;
424 tsm->set_num_nonzeros(num_nonzeros);
H A Dcovariance_impl.cc282 int num_nonzeros = 0; local
296 num_nonzeros += size1 * size2;
320 new CompressedRowSparseMatrix(num_rows, num_rows, num_nonzeros));
418 const int num_nonzeros = jacobian.values.size(); local
421 vector<SuiteSparse_long> transpose_cols(num_nonzeros, 0);
422 vector<double> transpose_values(num_nonzeros, 0);
424 for (int idx = 0; idx < num_nonzeros; ++idx) {
450 cholmod_jacobian.nzmax = num_nonzeros;

Completed in 145 milliseconds