Note
Click here to download the full example code
Save configure as a yaml file#
import os.path as path
from cherab.iter.tools import load_yml, dump_yml
config_file = path.join(path.dirname(__file__), "template.yml")
config = {
"ids": {
"shot": 122052,
"run": 1,
"time": 0,
"user": "public",
"machine": "iter",
"IDS": "Radiation",
"index_process": 0,
"index_element": 0,
"index_time": 0,
"nr": 450,
"nz": 950,
},
"rtm": {"rtm_use": True, "rtm_storage_dir": "../rtm/", "rtm_create": False},
"raytracing": {
"view": "DIM_EP1",
"species": "D0",
"dphi": 0.1,
"dtheta": 0.1,
"step": 0.0025,
"cutoff": 0.1,
"cutoff_frac": 0.01,
"wavelength": [200, 1000],
"min_samples": 1000,
"reflection": True,
},
}
dump_yml(config, config_file)
yml = load_yml(config_file)
print(yml)
Total running time of the script: ( 0 minutes 0.000 seconds)