Skip to content

Commit

Permalink
docs: add API documentation for benchmarking (#21)
Browse files Browse the repository at this point in the history
* docs: add API documentation for benchmarking

Signed-off-by: Elizabeth J Lee <elizabeth.j.lee@intel.com>
  • Loading branch information
ejlee3 authored May 7, 2024
1 parent a80114d commit e1fad36
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 5 deletions.
12 changes: 10 additions & 2 deletions Dockerfile.docs
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,17 @@
# Useful for local testing

FROM python:3-slim
RUN apt-get update && apt-get install --no-install-recommends -y git \
&& pip install mkdocs "mkdocs-material>=8.2" "mkdocs-htmlproofer-plugin>=0.8" "mkdocs-swagger-ui-tag" && \
RUN apt-get update && apt-get install --no-install-recommends -y git wget unzip \
&& pip install mkdocs "mkdocs-material>=8.2" "mkdocs-htmlproofer-plugin>=0.8" \
"mkdocs-swagger-ui-tag" "mkdocstrings>=0.24.3" "mkdocstrings-python>=1.9.2" && \
rm -rf /var/lib/apt/lists/*

WORKDIR /apis
RUN wget https://github.com/intel-retail/performance-tools/archive/refs/heads/main.zip
RUN unzip main.zip
WORKDIR /benchmark-scripts
RUN mv /apis/performance-tools-main/benchmark-scripts/* .

EXPOSE 8000
ENTRYPOINT ["mkdocs"]
CMD ["serve", "--dev-addr=0.0.0.0:8000"]
8 changes: 8 additions & 0 deletions docs_src/performance-tools/api-docs.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# API Documentation for Benchmark Scripts

## Benchmark Package

::: benchmark
handler: python
options:
show_source: false
10 changes: 7 additions & 3 deletions mkdocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ repo_name: "intel-retail/documentation"
repo_url: "https://github.com/intel-retail/documentation"
docs_dir: ./docs_src
site_dir: ./docs
copyright: 'Copyright &copy; 2023 Intel Corporation'
copyright: 'Copyright &copy; 2024 Intel Corporation'
use_directory_urls: false
theme:
name: 'material'
Expand All @@ -27,8 +27,11 @@ theme:
- toc.integrate
plugins:
- search
repo_url: https://github.com/intel-retail/documentation
repo_name: intel-retail/documentation
- mkdocstrings:
enable_inventory: true
handlers:
python:
paths: [../benchmark-scripts]
nav:
- Home: 'index.md'
- Architecture Decisions:
Expand All @@ -41,6 +44,7 @@ nav:
- Target Device: 'Architecture/target-device.md'
- Performance Tools:
- Benchmarking: 'performance-tools/benchmark.md'
- Benchmarking APIs: 'performance-tools/api-docs.md'
extra_css:
- ./stylesheets/index.css
- https://fonts.googleapis.com/icon?family=Material+Icons
Expand Down

0 comments on commit e1fad36

Please sign in to comment.