automatically convert datetime from python to c++
NOT from c++ to python since we may lose information