here we go.. bulk changes associated to pyinstaller/frozen binary distro. (1) wrap python scripts in functions to import instead of sys call, (2) create BIN_DIST/DB_DIR params to detect if frozen binary or not