Turn off WRITE_DEBUG_IMAGES by default. For testing, compile with `make CXXFLAGS=-DWRITE_DEBUG_IMAGES`