open file only once
This commit is contained in:
parent
c3a7a85f7a
commit
faa9e6aa6a
|
@ -1059,6 +1059,7 @@ class Result:
|
|||
attributes = []
|
||||
data_items = []
|
||||
|
||||
with h5py.File(self.fname,'r') as f:
|
||||
for inc in self.visible['increments']:
|
||||
|
||||
grid=ET.SubElement(collection,'Grid')
|
||||
|
@ -1084,8 +1085,6 @@ class Result:
|
|||
'Dimensions': '3'}
|
||||
delta.text="{} {} {}".format(*(self.size/self.cells))
|
||||
|
||||
|
||||
with h5py.File(self.fname,'r') as f:
|
||||
attributes.append(ET.SubElement(grid, 'Attribute'))
|
||||
attributes[-1].attrib={'Name': 'u / m',
|
||||
'Center': 'Node',
|
||||
|
|
Loading…
Reference in New Issue