Trisurf Monte Carlo simulator
Samo Penic
2016-02-29 bb40336eb8a2acc9f2e3d2e9059b7d90afe5c0c4
commit | author | age
82fa41 1 #!/usr/bin/python3
SP 2 import xml.etree.ElementTree as ET
588bbb 3 import base64
SP 4 import zlib
82fa41 5
SP 6 tree = ET.parse('../src/timestep_000000.vtu')
7 root = tree.getroot()
8 trisurf=root.find('trisurf')
9 print(trisurf.items())
588bbb 10 xml=zlib.decompress(base64.b64decode(trisurf.text))
82fa41 11
588bbb 12 tree2=ET.ElementTree(ET.fromstring("<root>"+str(xml)[0:-1]+"</root>"))