improve python bindings