Skip to content

Commit f33a178

Browse files
authored
Merge branch 'main' into testing_of_scripts
2 parents e6a4c28 + 338560a commit f33a178

File tree

10 files changed

+386
-24
lines changed

10 files changed

+386
-24
lines changed

.github/workflows/check_docs.yaml

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
name: Check docs
2+
3+
on:
4+
pull_request:
5+
branches: [main]
6+
7+
jobs:
8+
check:
9+
name: Check docs
10+
runs-on: ubuntu-latest
11+
steps:
12+
- name: Checkout code
13+
uses: actions/checkout@v4
14+
with:
15+
fetch-depth: 0
16+
17+
- name: Set up Python
18+
uses: actions/setup-python@v5
19+
with:
20+
python-version: 3.11
21+
cache: 'pip'
22+
cache-dependency-path: setup.py
23+
24+
- name: Install dependencies
25+
run: pip install -r requirements.txt
26+
27+
- name: Deploy docs
28+
run: mkdocs build -d build --strict
29+
30+
- name: Upload docs
31+
uses: actions/upload-artifact@v2
32+
with:
33+
name: docs
34+
path: build

figures/icons/locust.png

210 KB
Loading

figures/locust_page.png

81.7 KB
Loading

mkdocs.yml

Lines changed: 16 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -120,27 +120,28 @@ nav:
120120
- M22 - Requests and APIs: s7_deployment/apis.md
121121
- M23 - Local Deployment: s7_deployment/local_deployment.md
122122
- M24 - Cloud Deployment: s7_deployment/cloud_deployment.md
123+
- M25 - API Testing: s7_deployment/testing_apis.md
123124
- S8 - Monitoring 📊:
124125
- s8_monitoring/README.md
125-
- M25 - Data Drifting: s8_monitoring/data_drifting.md
126-
- M26 - System Monitoring: s8_monitoring/monitoring.md
126+
- M26 - Data Drifting: s8_monitoring/data_drifting.md
127+
- M27 - System Monitoring: s8_monitoring/monitoring.md
127128
- S9 - Scalable applications ⚖️:
128129
- s9_scalable_applications/README.md
129-
- M27 - Distributed Data Loading: s9_scalable_applications/data_loading.md
130-
- M28 - Distributed Training: s9_scalable_applications/distributed_training.md
131-
- M29 - Scalable Inference: s9_scalable_applications/inference.md
130+
- M28 - Distributed Data Loading: s9_scalable_applications/data_loading.md
131+
- M29 - Distributed Training: s9_scalable_applications/distributed_training.md
132+
- M30 - Scalable Inference: s9_scalable_applications/inference.md
132133
- S10 - Extra 🔥:
133134
- s10_extra/README.md
134-
- M30 - Command Line Interfaces: s10_extra/cli.md
135-
- M31 - Documentation: s10_extra/documentation.md
136-
- M32 - Hyperparameter optimization: s10_extra/hyperparameters.md
137-
- M33 - High Performance Clusters: s10_extra/high_performance_clusters.md
138-
# - M34 - Designing Pipelines: s10_extra/design.md
139-
# - M35 - Frontend: s10_extra/frontend.md
140-
# - M36 - Sharing models - ONNX format: s10_extra/onnx.md
141-
# - M37 - Workflow orchestration: s10_extra/orchestration.md
142-
# - M38 - Kubernetes: s10_extra/kubernetes.md
143-
# - M39 - Infrastructure as code: infrastructure_as_code.md
135+
- M31 - Command Line Interfaces: s10_extra/cli.md
136+
- M32 - Documentation: s10_extra/documentation.md
137+
- M33 - Hyperparameter optimization: s10_extra/hyperparameters.md
138+
- M34 - High Performance Clusters: s10_extra/high_performance_clusters.md
139+
# - M35 - Designing Pipelines: s10_extra/design.md
140+
# - M36 - Frontend: s10_extra/frontend.md
141+
# - M37 - Sharing models - ONNX format: s10_extra/onnx.md
142+
# - M38 - Workflow orchestration: s10_extra/orchestration.md
143+
# - M39 - Kubernetes: s10_extra/kubernetes.md
144+
# - M40 - Infrastructure as code: infrastructure_as_code.md
144145
- Summary: overview.md
145146
- Projects: projects.md
146147
# - Challenges: challenges.md

s10_extra/README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,24 +9,24 @@ Some of them may still be under construction and may in the future be moved into
99

1010
Learn how to setup a simple command line interface for your application
1111

12-
[:octicons-arrow-right-24: M30: Command Line Interfaces](cli.md)
12+
[:octicons-arrow-right-24: M31: Command Line Interfaces](cli.md)
1313

1414
- ![](../figures/icons/material.png){align=right : style="height:100px;width:100px"}
1515

1616
Learn how to setup a simple documentation system for your application
1717

18-
[:octicons-arrow-right-24: M31: Documentation](documentation.md)
18+
[:octicons-arrow-right-24: M32: Documentation](documentation.md)
1919

2020
- ![](../figures/icons/optuna.png){align=right : style="height:100px;width:100px"}
2121

2222
Learn how to do hyperparameter optimization using Optuna
2323

24-
[:octicons-arrow-right-24: M32: Hyperparameter Optimization](hyperparameters.md)
24+
[:octicons-arrow-right-24: M33: Hyperparameter Optimization](hyperparameters.md)
2525

2626
- ![](../figures/icons/pbs.png){align=right : style="height:100px;width:100px"}
2727

2828
Learn how to use HPC systems that use PBS to do job scheduling
2929

30-
[:octicons-arrow-right-24: M33: High Performance Clusters](high_performance_clusters.md)
30+
[:octicons-arrow-right-24: M34: High Performance Clusters](high_performance_clusters.md)
3131

3232
</div>

s7_deployment/README.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,12 @@
2222

2323
[:octicons-arrow-right-24: M24: Cloud Deployment](cloud_deployment.md)
2424

25+
- ![](../figures/icons/locust.png){align=right : style="height:100px;width:100px"}
26+
27+
Learn how to test APIs for functionality and load
28+
29+
[:octicons-arrow-right-24: M25: API testing](testing_apis.md)
30+
2531
</div>
2632

2733
Let's say that you have spent 1000 GPU hours and trained the most awesome model that you want to share with the
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
import random
2+
3+
from locust import HttpUser, between, task
4+
5+
6+
class MyUser(HttpUser):
7+
"""A simple Locust user class that defines the tasks to be performed by the users."""
8+
9+
wait_time = between(1, 2)
10+
11+
@task
12+
def get_root(self):
13+
"""A task that simulates a user visiting the root URL of the FastAPI app."""
14+
self.client.get("/")
15+
16+
@task(3)
17+
def get_item(self):
18+
"""A task that simulates a user visiting a random item URL of the FastAPI app."""
19+
item_id = random.randint(1, 10)
20+
self.client.get(f"/items/{item_id}")

0 commit comments

Comments
 (0)