You will find here tools to convert xml string into python dictionary and reciprocally. I used the python module pyexpat.