simplify python work