The information searched on the Internet is basically, let you turn on the zombie mode or cause the memory to crash due to the overflow of the array
wrong behavior
namedWindow( "gray_NAME" , CV_WINDOW_AUTOSIZE);
After using it, it was found that it was caused by the error of using imshow later, that is, because of the wrong content to be displayed, the error there
You can comment out imshow to find the problem