marota / ExpertOp4Grid

Expert System agent to operate a power grid
https://expertop4grid.readthedocs.io/en/latest
Mozilla Public License 2.0
7 stars 2 forks source link

Getting started command not working #30

Closed marota closed 3 years ago

marota commented 4 years ago

python -m alphaDeesp.main -l 9 -s 0 -c 0 -t 0

Error: We init Grid2OP Simulation Traceback (most recent call last): File "/opt/local/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/runpy.py", line 193, in _run_module_as_main "main", mod_spec) File "/opt/local/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/runpy.py", line 85, in _run_code exec(code, run_globals) File "/Users/antoinemarot/dev/ExpertOp4Grid/alphaDeesp/main.py", line 135, in main() File "/Users/antoinemarot/dev/ExpertOp4Grid/alphaDeesp/main.py", line 87, in main env, obs, action_space = loader.get_observation(chronic_scenario= args.chronicscenario, timestep=args.timestep) File "/Users/antoinemarot/dev/ExpertOp4Grid/alphaDeesp/core/grid2op/Grid2opObservationLoader.py", line 47, in get_observation raise ValueError("Chronic scenario name: "+chronic_scenario+" not found in folder") ValueError: Chronic scenario name: 0 not found in folder

marota commented 4 years ago

The names of the chronics are indeed "a" to "k". Here we give the index of the chronic, not its name, so it does not find a chronic

marota commented 4 years ago

@NMegel with the command line, we should be able to give either the name or the index of the scenario as input. So if we don't find a corresponding name, we should load the chronic with that index (if it is a number and in the range of chronics)

NMegel commented 4 years ago

Done in commit cdc35ce2e05d5afe17f701458f7547d4d514446a

NMegel commented 4 years ago

Chronic scenario was received as string by default, fixed in commit 987d48cbb655ef017dca7da8228b2af5c748cc17