put the python code into a singleton class to cleanup the namespace