Skip to content

Commit

Permalink
Add the benchmark summary from the release to the Sphinx documentation.
Browse files Browse the repository at this point in the history
  • Loading branch information
ernestum committed Nov 28, 2023
1 parent eb92458 commit 1505128
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 0 deletions.
15 changes: 15 additions & 0 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -132,3 +132,18 @@ def setup(app):
"autodoc-process-docstring",
no_namedtuple_attrib_docstring,
)


# -- Download latest benchmark summary -----------------------------------------------
import urllib.request
import zipfile
import io

download_url = "https://github.com/HumanCompatibleAI/imitation/releases/latest/download/benchmark_runs.zip"

# Download the data and run the summarization script
with urllib.request.urlopen(download_url) as url:
with zipfile.ZipFile(io.BytesIO(url.read())) as z:
with z.open("benchmark_runs/summary.md") as f:
with open("main-concepts/benchmark_summary.md", "wb") as out:
out.write(f.read())
1 change: 1 addition & 0 deletions docs/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@ If you use ``imitation`` in your research project, please cite our paper to help
main-concepts/reward_networks
main-concepts/variable_horizon
main-concepts/benchmarks
main-concepts/benchmark_summary


.. toctree::
Expand Down

0 comments on commit 1505128

Please sign in to comment.