diff options
author | Paweł Redman <pawel.redman@gmail.com> | 2019-05-02 19:54:26 +0200 |
---|---|---|
committer | Paweł Redman <pawel.redman@gmail.com> | 2019-05-02 19:59:49 +0200 |
commit | 6fcef36d90a66afd7c974748af7de2017f4f5792 (patch) | |
tree | 8859f434423fc7355f7c8c1e5b246ee2a6a516b6 /src/file.py | |
parent | b35ade41339ea95ec3c59eb45b813273304682e7 (diff) |
Input intensity
Diffstat (limited to 'src/file.py')
-rw-r--r-- | src/file.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/file.py b/src/file.py index 417c77b..3c69063 100644 --- a/src/file.py +++ b/src/file.py @@ -1,13 +1,13 @@ import re, sys, traceback, json import phys -file_format_version = 4 +file_format_version = 5 def save_system(path, system): ser = dict() + ser["input_intensity"] = system.input_intensity ser["version"] = file_format_version - ser["ignore"] = system.ignore ser["elements"] = [] for pol in system.elements: el = { @@ -36,7 +36,7 @@ def open_system(path): raise ValueError("Bad file version: expected %d, found %d" \ % (file_format_version, ser["version"])) - system.ignore = ser["ignore"] + system.input_intensity = float(ser["input_intensity"]) for el in ser["elements"]: pol = phys.Polarizer(str(el["type"])) |