I have a stripped-down example which shows how the CImg data is not being passed correctly between python3 (pycimg) and C++ on Ubuntu 20.04
CMakeFile.txt