-
Notifications
You must be signed in to change notification settings - Fork 134
Open
Labels
enhancementNew feature or requestNew feature or request
Description
Is your feature request related to a problem? Please describe.
It is not a problem, but something that could have some values, for example for debugging or even to help understand what is going on.
Today, we can achieve similar behviour by doing:
import grid2op
env_name = "l2rpn_case14_sandbox"
env = grid2op.make(env_name, ...)
obs = ... # an observation, from a runner or another environment.
saved_init_state = {"set_bus": obs.topo_vect, "injections": {"load_p": obs.load_p, "load_q": obs.load_q, "prod_p": obs.gen_p, "prod_v": obs.gen_v}}
similar_obs = obs = env.reset(options={"init state": saved_init_state})This is pretty verbose and does not consider the cooldowns, timestep_overflow of similar environment attributes.
Describe the solution you'd like
Ex. This is how i would like it to be done:
import grid2op
env_name = ...
env = grid2op.make(env_name, ...)
similar_obs = obs = env.reset(options={"init state": obs})Additional context
The "core" code should be pretty much done as this kind of feature is used for "ForecastedEnv" and for "obs.simulate" for example.
Only "glue code" should be done.
NB This would not keep the random state of the grid.
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request