1
0
mirror of https://github.com/ARM-software/devlib.git synced 2025-02-25 05:57:51 +00:00

utils/parse_aep: Correct typo in method arguments

This commit is contained in:
Marc Bonnici 2018-07-13 13:31:44 +01:00 committed by setrofim
parent 27fc75f74c
commit 3b0df282a9

View File

@ -291,7 +291,8 @@ class AepParser(object):
self.prepared = False self.prepared = False
def parse_aep(self, start=0, lenght=-1): # pylint: disable=too-many-branches,too-many-statements
def parse_aep(self, start=0, length=-1):
# Parse aep data and calculate the energy consumed # Parse aep data and calculate the energy consumed
begin = 0 begin = 0
@ -348,8 +349,8 @@ class AepParser(object):
if (data[0]-begin) < start: if (data[0]-begin) < start:
continue continue
# stop after lenght # stop after length
if lenght >= 0 and (data[0]-begin) > (start + lenght): if length >= 0 and (data[0]-begin) > (start + length):
continue continue
# add virtual domains # add virtual domains
@ -505,7 +506,7 @@ if __name__ == '__main__':
outfile = "" outfile = ""
figurefile = "" figurefile = ""
start = 0 start = 0
lenght = -1 length = -1
try: try:
opts, args = getopt.getopt(sys.argv[1:], "i:vo:s:l:t:") opts, args = getopt.getopt(sys.argv[1:], "i:vo:s:l:t:")
@ -524,7 +525,7 @@ if __name__ == '__main__':
if o == "-s": if o == "-s":
start = int(float(a)*1000000) start = int(float(a)*1000000)
if o == "-l": if o == "-l":
lenght = int(float(a)*1000000) length = int(float(a)*1000000)
if o == "-t": if o == "-t":
topofile = a topofile = a
parser = AepParser() parser = AepParser()
@ -533,4 +534,4 @@ if __name__ == '__main__':
parser = AepParser() parser = AepParser()
parser.prepare(infile, outfile, figurefile) parser.prepare(infile, outfile, figurefile)
parser.parse_aep(start, lenght) parser.parse_aep(start, length)