CGAL / cgal

The public CGAL repository, see the README below
https://github.com/CGAL/cgal#readme
Other
4.92k stars 1.38k forks source link

Orthtree test error #7080

Closed sloriot closed 1 year ago

sloriot commented 1 year ago

I can reproduce this error [test_octree_grade.cpp, seed = 1669157241] with master.

afabri commented 1 year ago

I think this assertion makes no sense. We create an octree for a random point set and refine the tree. Depending on the input it may just happen that there is nothing to do for the grade() function. It is like an assert that a random sequence of numbers was not sorted before you call std::sort(). @palliez @JacksonCampolattaro can you confirm.

JacksonCampolattaro commented 1 year ago

I think this assertion makes no sense. We create an octree for a random point set and refine the tree. Depending on the input it may just happen that there is nothing to do for the grade() function. It is like an assert that a random sequence of numbers was not sorted before you call std::sort(). @palliez @JacksonCampolattaro can you confirm.

That can probably be removed. I think my logic at the time was that if the random point set happens to produce a tree with no jumps, then that unit test wouldn't actually confirm that grade() was functioning correctly. In practice that likely never happens.

afabri commented 1 year ago

It even then confirms that grade() does the right thing, namely just nothing.