diff options
author | Karel Kočí <cynerd@email.cz> | 2015-04-27 21:33:40 +0200 |
---|---|---|
committer | Karel Kočí <cynerd@email.cz> | 2015-04-27 21:33:40 +0200 |
commit | 1a898f0d9ed617026ad50d6bc61fdee919326e9e (patch) | |
tree | 2a00d69b213239072731bad9e3b8eeabb637f3d0 /scripts | |
parent | e89081c8ae3ba5cc42a7f387b267f02ea5a4e8f1 (diff) | |
download | linux-conf-perf-1a898f0d9ed617026ad50d6bc61fdee919326e9e.tar.gz linux-conf-perf-1a898f0d9ed617026ad50d6bc61fdee919326e9e.tar.bz2 linux-conf-perf-1a898f0d9ed617026ad50d6bc61fdee919326e9e.zip |
Add output_confs generation to solution apply
Diffstat (limited to 'scripts')
-rw-r--r-- | scripts/solution.py | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/scripts/solution.py b/scripts/solution.py index 3fddb6b..b3bec30 100644 --- a/scripts/solution.py +++ b/scripts/solution.py @@ -78,6 +78,15 @@ def apply(): solut = f.readline().split() solut.remove('0') # Remove 0 at the end + # Write solution to output_confs file + with open(sf(conf.output_confs), 'a') as f: + iteration = 0 + with open(sf(conf.iteration_file)) as f: + iteration = int(f.readline) + f.write(str(iteration) + ':') + for txt in solut: + f.write(txt + ' ') + f.write('\n') # Write negotation solution to solver_file |