S
Stephen Boulet
I have a long list of floats (1613808 elements long). It takes quite a
while to load this into a 7 dimensional Numeric array.
Is there any obvious way to speed this up?
def insertData(self,data):
# Start off with an array of the desired size
# "self.MEASURED", etc., are integers
arrayData = zeros([self.MEASURED, self.SWEPT, \
self.TEMPS,self.DCS, self.IVS, self.UUTS, \
self.DUTS], Float64)
i = 0
for device in range(self.DUTS):
for unit in range(self.UUTS):
for iv in range(self.IVS):
for dc in range(self.DCS):
for temp in range(self.TEMPS):
for swept in range(self.SWEPT):
for measured in range(self.MEASURED):
arrayData[measured][swept][temp][dc][iv][unit][device] = bigList
i += 1
return arrayData
Stephen
while to load this into a 7 dimensional Numeric array.
Is there any obvious way to speed this up?
def insertData(self,data):
# Start off with an array of the desired size
# "self.MEASURED", etc., are integers
arrayData = zeros([self.MEASURED, self.SWEPT, \
self.TEMPS,self.DCS, self.IVS, self.UUTS, \
self.DUTS], Float64)
i = 0
for device in range(self.DUTS):
for unit in range(self.UUTS):
for iv in range(self.IVS):
for dc in range(self.DCS):
for temp in range(self.TEMPS):
for swept in range(self.SWEPT):
for measured in range(self.MEASURED):
arrayData[measured][swept][temp][dc][iv][unit][device] = bigList
i += 1
return arrayData
Stephen