Open pengsongyou opened 3 years ago
I tried to figure out the case of this memory issue. While not fully successful, I have narrowed it down to this function ConstNeighborKey3::~ConstNeighborKey3
.
The original PoissonRecon V6.13 code is now very old and is failing to keep up with the stricter checks of the new compilers, python, and cython. While I am not fully sure, I strongly suspect the latest gcc is putting additional constraints on how the memory is freed, and some of the old pointer-stuff is failing. This is a very useful piece of code, so if someone wants to volunteer to update all the pointer/array usage into std::vector, it would be a great community service. :-)
Immediate solution: until that happens, I was able to run this using gcc@7. I used the following. Hope this helps. It seems from comments above that others have also had success in rolling back os/gcc.
gcc-mp-7 (MacPorts gcc7 7.5.0_2) 7.5.0
Python 3.7.11
Cython version 0.29.24
I switch to gcc-7 and recompile, then the segmentation fault
disappears.
First, of all, thanks a lot for the amazing python binder for SPSR!
I am using Ubuntu 20.04, python=3.7.3, cython 0.29.12, GCC 7.3.
Following the readme file, I have successfully installed it. However, when I was trying to run your example folder, I encountered the error as below:
I was trying to debug, and realize the issue happening inside this line. Then, I tried to compiled and ran examples using the original PoissonRecon V6.13 code, it also worked perfectly. Therefore, I think the problem might come when compiling with the cython?
I then changed another machine with Ubuntu 18.04, and it worked with your tool. Therefore, I am just curious what could be the possible reasons.
Thanks a lot for your effort in advance!
Best, Songyou