-
Notifications
You must be signed in to change notification settings - Fork 113
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #159 from BDonnot/master
upgrade to version 1.3.0
- Loading branch information
Showing
290 changed files
with
11,537 additions
and
868 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -22,4 +22,4 @@ workflows: | |
version: 2.1 | ||
test: | ||
jobs: | ||
- test | ||
- test |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,60 @@ | ||
Episode | ||
=================================== | ||
Objectives | ||
----------- | ||
Grid2op defines some special function that help with restoring agent that has run during some episode that has been | ||
saved by the runner. | ||
|
||
Here are some basic usage. | ||
|
||
First you run an episode: | ||
|
||
.. code-block:: python | ||
import grid2op | ||
from grid2op.Runner import Runner | ||
# I create an environment | ||
env = grid2op.make("rte_case5_example", test=True) | ||
# I create the runner | ||
runner = Runner(**env.get_params_for_runner()) | ||
path_save = "/I/SAVED/RESULTS/THERE" | ||
# I start the runner and save the results in "/I/SAVED/RESULTS/THERE" | ||
# I start the evaluation on 2 different episode | ||
res = runner.run(path_save=path_save, nb_episode=2) | ||
Second you can reload the data (here to plot the different productions active values): | ||
|
||
.. code-block:: python | ||
import grid2op | ||
from grid2op.Episode import EpisodeData | ||
# I study only the first episode saved, because... why not | ||
path_saved = "/I/SAVED/RESULTS/THERE" # same path as before | ||
li_episode = EpisodeData.list_episode(path_saved) | ||
full_path, episode_studied = li_episode[0] | ||
this_episode = EpisodeData.from_disk(path_agent, episode_studied) | ||
# now the episode is loaded, and you can easily iterate through the observation, the actions etc. | ||
for act in this_episode.actions: | ||
print(act) | ||
for i, obs in enumerate(this_episode.observations): | ||
print("At step {} the active productions were {}".format(i, obs.prod_p)) | ||
# etc. etc. | ||
Detailed Documentation by class | ||
-------------------------------- | ||
.. automodule:: grid2op.Episode | ||
:members: | ||
:autosummary: | ||
|
||
.. include:: final.rst | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -87,6 +87,7 @@ Technical Documentation | |
chronics | ||
converter | ||
environment | ||
episode | ||
rules | ||
observation | ||
opponent | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.