WIP: The eclipse gride preprocessing is not allowed to deactivate cells#393
WIP: The eclipse gride preprocessing is not allowed to deactivate cells#393joakim-hove wants to merge 2 commits into
Conversation
|
|
||
| { | ||
| const auto& ecl_actnum = ecl_grid.getACTNUM(); | ||
| for (std::size_t g = 0; g < ecl_grid.getCartesianSize(); g++) { |
There was a problem hiding this comment.
Using g for cell index is a little weird...? Other than that trivial observation, I'll try to run this through some cases to see if it is triggered.
There was a problem hiding this comment.
I like using g for global_index - happy to change it thougth.
| // Make the grid. | ||
| processEclipseFormat(g, nnc_cells, z_tolerance, false, turn_normals); | ||
| } | ||
|
|
There was a problem hiding this comment.
Should we maybe deactivate this test in production by #ifndef NDEDUG
There was a problem hiding this comment.
Better safe than sorry - I would prefer to leave that test in - even in release mode; can add a commented of #ifndef NDEBUG - which can be activated at some point in the future.
| { | ||
| const auto& ecl_actnum = ecl_grid.getACTNUM(); | ||
| for (std::size_t g = 0; g < ecl_grid.getCartesianSize(); g++) { | ||
| if (ecl_actnum[g] != g.actnum[g]) |
There was a problem hiding this comment.
Are you sure this compiles? Looks like you are calling a member function on a g which is of type size_t here.
There was a problem hiding this comment.
Hehe - no this probably does not compile ... :-(
630b3b3 to
3eb9dc3
Compare
3eb9dc3 to
9f861fd
Compare
This switch is added to be able to support the grid construction from opm-upscaling.
|
Closing this one as the companion PR is closed (and pinch processing might also deactivate cells. There is hope that that processing will move to an earlier stage and the changes in opm-common will really make sense. |
Related to: OPM/opm-common#1059
Observe that the uglyness in the second commit is to support opm-upscaling: OPM/opm-upscaling#279