supporting module for pyselfe_v1.py