Skip to content
Snippets Groups Projects
Commit b9a8dafb authored by Michael Reuscher's avatar Michael Reuscher
Browse files

new working animation

parent f0899894
No related branches found
No related tags found
1 merge request!4Python driver and data analysis part
...@@ -6,7 +6,6 @@ import os ...@@ -6,7 +6,6 @@ import os
def create_size_list(length): def create_size_list(length):
start = 16 start = 16
size_list = [start * (2 ** i) for i in range(length)] size_list = [start * (2 ** i) for i in range(length)]
print(size_list)
return size_list return size_list
...@@ -38,7 +37,6 @@ def set_arguments_various(da_config, test_data_path, args): ...@@ -38,7 +37,6 @@ def set_arguments_various(da_config, test_data_path, args):
event_arguments['-o'] = event_name event_arguments['-o'] = event_name
e_dict[event_name] = event_arguments e_dict[event_name] = event_arguments
# Gib das Dictionary der Ereignisargumente für verschiedene Byte-Größen zurück # Gib das Dictionary der Ereignisargumente für verschiedene Byte-Größen zurück
print(e_dict)
return e_dict return e_dict
......
...@@ -5,7 +5,7 @@ ...@@ -5,7 +5,7 @@
"-N": "12"}, "-N": "12"},
"data_config_long":{ "data_config_long":{
"-s": "1024", "-s": "1024",
"-n": "5000", "-n": "100",
"-i": "0.1s", "-i": "0.1s",
"-N": "4"}, "-N": "4"},
"data_config_help":{ "data_config_help":{
......
import os import os
import sys
import time import time
import signal import signal
import subprocess import subprocess
...@@ -101,7 +102,16 @@ def run(e_dict, main_path): ...@@ -101,7 +102,16 @@ def run(e_dict, main_path):
future = executor.submit(local_simulation, args.sim, e_dict[event], output_path) future = executor.submit(local_simulation, args.sim, e_dict[event], output_path)
futures.append((folder_name, None, future)) futures.append((folder_name, None, future))
# Animierte Anzeige (z.B. sich drehende Röhre)
animation = ['|', '/', '-', '\\']
animation_index = 0
for folder_name, host, future in futures: for folder_name, host, future in futures:
while not future.done():
sys.stdout.write('\rWorking ' + animation[animation_index])
sys.stdout.flush()
animation_index = (animation_index + 1) % len(animation)
time.sleep(0.1)
output, errors, result = future.result() output, errors, result = future.result()
terminal_msg = f'{folder_name}_{host if host else ""} done!' terminal_msg = f'{folder_name}_{host if host else ""} done!'
if not stop_requested: if not stop_requested:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment