now understands packed geom structure
This commit is contained in:
parent
76171eec15
commit
5f347648e1
|
@ -142,9 +142,15 @@ for file in files:
|
||||||
|
|
||||||
i = 0
|
i = 0
|
||||||
for line in content:
|
for line in content:
|
||||||
d = map(int,line.split())
|
items = line.split()
|
||||||
s = len(d)
|
if len(items) > 2:
|
||||||
microstructure[i:i+s] = d # read microstructure indices
|
if items[1].lower() == 'of': items = [int(items[2])]*int(items[0])
|
||||||
|
elif items[1].lower() == 'to': items = xrange(int(items[0]),1+int(items[2]))
|
||||||
|
else: items = map(int,items)
|
||||||
|
else: items = map(int,items)
|
||||||
|
|
||||||
|
s = len(items)
|
||||||
|
microstructure[i:i+s] = items # read microstructure indices
|
||||||
i += s
|
i += s
|
||||||
|
|
||||||
for i in xrange(N):
|
for i in xrange(N):
|
||||||
|
|
Loading…
Reference in New Issue