changed structure in python wrapper