Updated python interface