-
-
Notifications
You must be signed in to change notification settings - Fork 44
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
49 additions
and
5 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 |
---|---|---|
@@ -1,5 +1,6 @@ | ||
name: Build Documentation website | ||
on: | ||
pull_request: | ||
push: | ||
branches: [main] | ||
permissions: | ||
|
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,23 @@ | ||
|
||
from absl import app, flags | ||
|
||
from gymnasium.envs.registration import EnvSpec | ||
|
||
from minari.utils import get_env_spec_dict | ||
from md_utils import dict_to_table | ||
|
||
FLAGS = flags.FLAGS | ||
flags.DEFINE_string("env_spec", None, "Environment spec json file") | ||
flags.DEFINE_string("file_name", None, "File name to save the md file") | ||
|
||
|
||
def main(argv): | ||
del argv | ||
env_spec_dict = get_env_spec_dict(EnvSpec.from_json(FLAGS.env_spec)) | ||
md_table = dict_to_table(env_spec_dict) | ||
with open(FLAGS.file_name, "w") as f: | ||
f.write(md_table) | ||
|
||
|
||
if __name__ == "__main__": | ||
app.run(main) |