| 413 | } |
| 414 | |
| 415 | int NumResidualBlocks() { |
| 416 | // Verify that the hash set of residuals is maintained consistently. |
| 417 | if (GetParam()) { |
| 418 | EXPECT_EQ(problem->residual_block_set().size(), |
| 419 | problem->NumResidualBlocks()); |
| 420 | } |
| 421 | return problem->NumResidualBlocks(); |
| 422 | } |
| 423 | |
| 424 | // The next block of functions until the end are only for testing the |
| 425 | // residual block removals. |