Releases: Grid2op/grid2op
Releases · Grid2op/grid2op
Release version 1.5.1
Fixed issues
- Issue #187: improve the computation and the
documentation of theRedispReward
. This has an impact on theenv.reward_range
of all environments using this
reward, because the old "reward_max" was not correct. - Issue #181 : now environment can be created with
a layout and a warning is issued in this case. - Issue #180 : it is now possible to set the thermal
limit with a dictionary - a typo that would cause the attack to be discarded in the runner in some cases (cases for now not used)
- an issue linked to the transformation into gym box space for some environments,
this might be linked to Issue #185
Addition
- A feature to retrieve the voltage angle (theta) in the backend (
backend.get_theta
) and in the observation. - Support for multimix in the GymEnv (lack of support spotted thanks to Issue #185
- Basic documentation of the environment available.
- Issue #166 : support for simulate in multi environment settings.
Improvements
- Extra layer of security preventing modification of
observation_space
andaction_space
of environment - Better handling of dynamically generated classes
- The documentation of the opponent
Release version 1.5.0
Changelog
Breaking changes
backend.check_kirchoff()
method now returns also the discrepancy in the voltage magnitude and not only the error in the P and Q injected at each bus.- the class method "to_dict" used to serialize the action_space and observation_space has been renamed cls_to_dict to avoid confusion with the to_dict method of action and observation (that stores, as dictionary the instance of the action / observation). It is now then possible to serialize the action class used and the observation class used as dictionary to (using action.cls_to_dict)
- for backend class implementation: need to upgrade your code to take into account the storage units if some are present in the grid even if you don't want to use storage units.
- the backend runpf method now returns a flag indicating if the simulation was successful AND (new) the exception in case there are some (it now returns a tuple). This change only affect new Backends.
- rename the attribute "parameters" of the "observation_space" to _simulate_parameters to avoid confusion with the parameters attributes of the environment.
- change of behaviour of the env.parameters attribute behaviour. It is no more possible to modified it with env.parameters = ... and the env.parameters.PARAM_ATTRIBUTE = xxx will have not effect at all. Use env.change_parameters(new_parameters) for changing the environment parameters and env.change_forecast_parameters(new_param_for_simulate) for changing the parameters used for simulate. (NB in both case you need to perform a "env.reset()" for the new parameters to be used. Any attempt to use an environment without a call to 'env.reset()' will lead to undefined behaviour).
- env.obs_space.rewardClass is not private and is called env.obs_space._reward_func. To change this function, you need to call env.change_reward(...)
- more consistency in the observation attribute names, they are now gen_p, gen_q and gen_v instead of prod_p, prod_q and prod_v (old names are still accessible for backward compatibility in the observation space) but conversion to json / dict will be affected as well as the converters (eg for gym compatibility)
Fixed issues
- Issue #164: reward is now properly computed at the end of an episode.
- A bug where after running a Runner, the corresponding EpisodeData's CollectionWrapper where not properly updated, and did not contain any objects.
- A bug when the opponent should chose an attack with all lines having flow 0, but one being still connected.
- An error in the obs.flow_bus_matrix when active_flow=False and there were shunts on the powergrid.
- obs.connectivity_matrix now properly takes into account when two objects are disconnected (before it was as if there were connected together)
- some surprising behaviour when using obs.simulate just before or just after a planned maintenance operation.
- a minimal bug in the env.copy method (the wrong simulated backend was used in the observation at right after the copy).
- a bug in the serialization (as vector) of some action classes, namely: PowerlineSetAction and PowerlineSetAndDispatchAction and PowerlineChangeDispatchAndStorageAction
- a bug preventing to use the obs.XXX_matrix() function twice
- issue Issue #172 : wrong assertion was made preventing the use of env.train_val_split_random()
- issue Issue #173 : a full nan vector could be converted to action or observation without any issue if it had the proper dimension. This was due to a conversion to integer from float.
- an issue preventing to load the grid2op.utils submodule when installed not in "develop" mode
- some issue with the multiprocessing of the runner on windows
New features
- more complete documentation for the runner.
- a convenient function to evaluate the impact (especially on topology) of an action on a state (obs + act)
- a property to retrieve the thermal limits from the observation.
- documentation of the main elements of the grid and their "modeling" in grid2op.
- parameters are now checked and refused if not valid (a RuntimeError is raised)
- support for storage unit in grid2op (analog as a "load" convention positive: power absorbed from the grid, negative: power given to the grid having some energy limit and power limit). A new object if added in the substation.
- Support for sparse matrices in obs.bus_connectivity_matrix
- In the observation, it is now possible to retrieve the "active flow graph" (ie graph with edges having active flows, and nodes the active production / consumption) and "reactive flow graph" (see flow_bus_matrix)
- more consistent behaviour when using the action space across the different type of actions. Now it should understand much more way to interact with it.
- lots of action properties to manipulate action in a more pythonic way, for example using act.load_set_bus = ... instead of the previously way more verbose act.update({"set_bus": {"loads_id": ...}} (this applies for load, gen, storage, line_or and line_ex and to set_bus and change_bus and also to storage_p and redispatch so making 12 "properties" in total)
- an option to retrieve in memory the EpisodeData of each episode computed when using the runner. see runner.run(..., add_detailed_output=True)
- the option as_csr_matrix in obs.connectivity_matrix function
- convenient option to get the topology of a substation from an observation (obs.sub_topology(sub_id=...))
- some basic tests for the environments shipped with grid2op.
- grid2op now ships with the l2rpn_case14_sandbox environment
- a function to list environments available for testing / illustration purpose.
- a function of the observation to convert it to a networkx graph (obs.as_networkx())
- support for curtailment feature in grid2op (curtailment on the renewable generator units).
- better backward compatibility when reading data generated with previous grid2op version.
Improvements
- simplify the interface for the gym converter.
- simplify the interface for the env.train_val_split and env.train_val_split_random
- print of an action now limits the number of decimal for redispatching and storage units
Version 1.4.0
v1.4.0 Release v1.4.0