Once the calculation is running through Python, there should be a standard way to stop it (without `kill`). [Here](https://pybind11.readthedocs.io/en/stable/faq.html?highlight=cmake#how-can-i-properly-handle-ctrl-c-in-long-running-functions) is a hint how to implement it.