title: Python: Parse SVG / XML with namespace
body: <p>Parsing an xml file (svg in this case) in Python is convenient, but as soon as there are namespaces involved, nothing works. What is the right way to work with Pythons xml library?</p>
  
  <p>If my file had no namespace, I could easily do the following code and get all the elements:</p>
  
  <pre><code>import xml.etree.ElementTree as ET
  tree = ET.parse('model1.svg')  
  root = tree.getroot()
  lst = root.findall('g/g/g/g')
  print(lst)
  </code></pre>
  
  <p>But since it has a namespace:</p>
  
  <pre><code>&lt;svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" id="temp" width="1809.6200256347656" height="1247.809829711914" version="1.1" viewBox="0 0 1809.6200256347656 1247.809829711914"&gt;
  </code></pre>
  
  <p>The response is: <code>[]</code></p>
  
  <p>If I try to print the <code>root</code> I get this :</p>
  
  <pre><code>&lt;Element '{http://www.w3.org/2000/svg}svg' at 0x7fbc45154ea8&gt;
  </code></pre>
  
  <p>instead of this: </p>
  
  <pre><code>&lt;Element 'svg' at 0x7f8ee9377368&gt;
  </code></pre>
  
  <p>So I just can't work with it. How can I deactivate/ignore it?</p>