Commit 2e5cf367 by Tobias Langer

Added support for utilization task generation.

parent 416f5a30
...@@ -14,8 +14,11 @@ def get_exp_cnt(path): ...@@ -14,8 +14,11 @@ def get_exp_cnt(path):
def main(): def main():
parser = argparse.ArgumentParser('Run all the scripts so everything works fine.') parser = argparse.ArgumentParser('Run all the scripts so everything works fine.')
parser.add_argument('experiments', type=int, nargs='?', default=1, parser.add_argument('experiments', type=int, nargs=1, default=1,
help='The number of experiments to be run.') help='The number of experiments to be run.')
parser.add_argument('utilization', type=float, nargs='?', default=1,
help='The utilization for the experiments to be run.',
default=None)
args = parser.parse_args() args = parser.parse_args()
cwd = os.getcwd() cwd = os.getcwd()
...@@ -29,9 +32,16 @@ def main(): ...@@ -29,9 +32,16 @@ def main():
cnt = 0 cnt = 0
remain = args.experiments remain = args.experiments
while remain > 0: while remain > 0:
subprocess.call(['./tasksetgen.py', '--microseconds', '--uniform', '5', if parser.utilization is not None:
str(remain), 'experiments/ese2016_{}'.format(cnt), subprocess.call(['./tasksetgen.py', '--microseconds', '--uniform', '5',
'experiment_data']) '--utilization {}:{}'.format(args.utilization - 0.25, args.utilization + 0.25),
str(remain), 'experiments/ese2016_{}'.format(cnt),
'experiment_data'])
else:
subprocess.call(['./tasksetgen.py', '--microseconds', '--uniform', '5',
str(remain), 'experiments/ese2016_{}'.format(cnt),
'experiment_data'])
for experiment in os.listdir('experiments/ese2016_{}'.format(cnt)): for experiment in os.listdir('experiments/ese2016_{}'.format(cnt)):
subprocess.call(['./generate.py', subprocess.call(['./generate.py',
'experiments/ese2016_{}'.format(cnt) + '/' + experiment]) 'experiments/ese2016_{}'.format(cnt) + '/' + experiment])
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment