Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Training freeze when raise a RuntimeError in EnergyPlus #16

Open
hermmanhender opened this issue Sep 6, 2023 · 2 comments
Open

Training freeze when raise a RuntimeError in EnergyPlus #16

hermmanhender opened this issue Sep 6, 2023 · 2 comments
Labels
enhancement New feature or request

Comments

@hermmanhender
Copy link

Hi, I used this repo as base for my own development.

I found that the comand raise RuntimeError(f"EnergyPlus failed with {self.energyplus_runner.sim_results['exit_code']}") in line 359 of run.py file (in step() method) freeze the simulation when an error apears.

I solved this problem changing this line for raise Exception(Faulty episode) and adding the following to the Tune configuration for running the experiment:

tune.Tuner(
    algorithm_name,
    run_config = air.RunConfig(
        stop = {'episode_total': 250},
        failure_config = air.FailureConfig(
        # Tries to recover a run up to this many times.
        max_failures=10
        )
    ),
    param_space=algo_config.to_dict(),
).to_fit()

This was helpful for me.

@antoine-galataud
Copy link
Member

Hi @hermmanhender, thank you for sharing your experience on this. That's indeed very useful in case some EnergyPlus runs are expected to fail. I'm curious to know why? That must be specific to your work?

@hermmanhender
Copy link
Author

You're welcome, it seemed important to me, since when you run EnergyPlus in different threads and on a recurring basis, from my experience, there are always chances of errors. In my case, a very peculiar error is occurring that I still can't solve, which I have published in UnmetHours (here).

In addition, I am having problems when I run a full year with some algorithms from the RLlib library, but perhaps changing the configuration I can solve it (I still have to experiment) because with shorter running time periods it works well (up to three months I have tried without faults).

@antoine-galataud antoine-galataud added the enhancement New feature or request label Nov 29, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants