CGAL / cgal

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

create_interior_straight_skeleton_2 using too much memory and time #8137

Open loftyscholar opened 2 months ago

loftyscholar commented 2 months ago

Please use the following template to help us solving your issue. err_poly.zip

Issue Details

When I call the CGAL::create_interior_straight_skeleton_2() function to extract the skeleton line, it cost more than 40 GB memory and one-hour time. Actually, the final result is right. And I tried to repair it with CGAL::Polygon_repair::repair(), but it didn't help. If I resolved the self intersections manually, this problem could be solved. I am wondering if there are some ways of detecting the self-intersections and repair them?

Source Code

SsPtr iss = CGAL::create_interior_straight_skeleton_2(poly);

If your issue arises by using CGAL in your own source code, please provide a minimalist example that we can compile easily to reproduce the bug. If your issue arises from using a CGAL program (demo, example, etc.), please let us know which one. Helping you solving an issue is much easier and efficient if we can reproduce it.

Environment

MaelRL commented 2 months ago

Please provide the complete code, including the code to transcribe your data into the CGAL input.

loftyscholar commented 2 months ago

Please provide the complete code, including the code to transcribe your data into the CGAL input.

Please see the attached code file, thanks for your help. code.txt