- KSTAR is a tokamak (donut-shaped nuclear fusion reactor) located in South Korea.
- This repository describes an AI that designs the tokamak operation trajectory to control the fusion plasma in KSTAR.
- Here, we would like to control 3 physics parameters; βp, q95 and li.
- I recommend you to see KSTAR Tokamak Simulator first. The manual control of it is replaced by AI here.
- You can install by
$ git clone https://github.com/jaem-seo/AI_tokamak_control.git
$ cd AI_tokamak_control
- Open the GUI. It takes a bit (tens of secconds) depending on your environment.
$ python ai_control_v0.py
or
$ python ai_control_v1.py
- Slide the toggles on the right to change the targets and click the "AI control" button (it takes tens of seconds).
- Then, the AI will design the tokamak operation trajectory to achieve the given target in 4 s.
- Open the GUI. It takes a bit (tens of secconds) depending on your environment.
$ python rt_control_v2.py
- Slide the toggles on the right to change the target state.
- Then, the AI will control the tokamak operation to track the targets in real-time.
- The AI was trained by reinforcement learning; TD3 and HER implementation from Stable Baselines.
- The AI control can fail if the target state is physically unfeasible (ex. high-βp, low-q95 and high-li).
- The tokamak simulation possesses most of the computation time, but the AI operation control is actually very fast (real-time capable in experiments).
- Deployment on the KSTAR control system will require further development.
- A. Hill et al. "Stable Baselines." GitHub repository (2018).
- S. Fujimoto et al. "Addressing Function Approximation Error in Actor-Critic Methods." ICML (2018).
- M. Andrychowicz et al. "Hindsight Experience Replay." NIPS (2017).
- J. Seo, "KSTAR tokamak simulator." GitHub repository (2022).
- J. Seo, et al. "Feedforward beta control in the KSTAR tokamak by deep reinforcement learning." Nuclear Fusion 61 (2021): 106010.
- J. Seo, et al. "Development of an operation trajectory design algorithm for control of multiple 0D parameters using deep reinforcement learning in KSTAR." Nuclear Fusion 62 (2022): 086049.