-
Notifications
You must be signed in to change notification settings - Fork 7
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 #438 from awslabs/dev
Release 0.4.0
- Loading branch information
Showing
258 changed files
with
7,103 additions
and
2,619 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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,69 @@ | ||
name: SageMaker Tests | ||
|
||
# All tests in this file: | ||
# 1. Run when launched manually | ||
# 2. Require AWS credentials and launch training jobs | ||
|
||
on: | ||
workflow_dispatch: | ||
# pull_request: # UNCOMMENT FOR TESTING | ||
# branches: # UNCOMMENT FOR TESTING | ||
# - main # UNCOMMENT FOR TESTING | ||
# - dev # UNCOMMENT FOR TESTING | ||
|
||
env: | ||
AWS_DEFAULT_REGION: us-west-2 | ||
AWS_ROLE: ${{ secrets.PROD_AWS_END_TO_END_TEST_ROLE_ARN }} | ||
|
||
permissions: | ||
id-token: write # This is required for requesting the JWT | ||
contents: read # This is required for actions/checkout | ||
|
||
jobs: | ||
launch-sagemaker-jobs: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: actions/setup-python@v4 | ||
with: | ||
python-version: 3.9 | ||
cache: 'pip' | ||
- name: Install Renate | ||
run: | | ||
python -m pip install --upgrade pip | ||
python -m pip install -e '.[dev]' | ||
- name: Install toml library | ||
run: pip install toml | ||
- name: Write requirements.txt for SageMaker training jobs | ||
run: | | ||
python test/integration_tests/generate_requirements.py | ||
- name: Get Credentials | ||
uses: aws-actions/configure-aws-credentials@v4 | ||
with: | ||
role-to-assume: ${{ secrets.PROD_AWS_END_TO_END_TEST_ROLE_ARN }} | ||
role-session-name: integtestsession | ||
aws-region: ${{ env.AWS_DEFAULT_REGION }} | ||
- name: Launch SageMaker Jobs | ||
run: | | ||
import os | ||
import subprocess | ||
target_directory = 'test/integration_tests/configs/suites/main' | ||
files = [f for f in os.listdir(target_directory) if os.path.isfile(os.path.join(target_directory, f))] | ||
for file in files: | ||
process = subprocess.Popen( | ||
[ | ||
"python", | ||
"test/integration_tests/run_test.py", | ||
"--test-file", | ||
file, | ||
"--seed", | ||
"0", | ||
"--requirements-file", | ||
"test/integration_tests/requirements.txt", | ||
] | ||
) | ||
process.wait() | ||
shell: python |
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,35 @@ | ||
Running Standard Benchmarks | ||
****************************************************************************** | ||
|
||
This folder contains a couple of files to run experiments with Renate. | ||
Add new experimentation configuration files to add new experiments. | ||
Edit the ``requirements.txt`` to add additional requirements for an experiment (SageMaker only). | ||
|
||
Instructions | ||
============ | ||
1. Clone the repository | ||
2. ``cd Renate`` and install Renate | ||
3. Run a benchmark via | ||
|
||
.. code-block:: bash | ||
python benchmarks/run_benchmark.py --benchmark-file fine-tuning-clear10.json \ | ||
--backend sagemaker --budget-factor 1 --job-name clear10-finetuning-1 --num-repetitions 1 | ||
This is an example command to run an experiment with ClEAR10 on SageMaker using a Fine-Tuning | ||
updater. | ||
|
||
Quick explanation of the arguments: | ||
|
||
- ``benchmark-file``: Any filename of files in ``experiment_configs``. This file specifies all | ||
properties of the experiment, i.e., dataset, scenario, updater, and hyperparameters settings. | ||
Modify or add more to run own experiments. | ||
- ``backend``: Run the experiment on SageMaker (``sagemaker``) or locally (``local``). | ||
- ``budget-factor``: Each update run will make ``budget_factor * max_epochs`` many passes over | ||
the new data during training. ``max_epochs`` is typically defines as part of the scenario | ||
.json file. Default: ``1``. | ||
- ``job-name``: Defines the name of the output folder and the name of the SageMaker training | ||
job. | ||
- ``num-repetitions``: The number of times the experiment will be repeated. Only the seed | ||
differs between repetitions. | ||
- ``max-time``: The wall clock time spent per update. Default: 5 days. |
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,6 @@ | ||
{ | ||
"dataset_name": "arxiv", | ||
"src_bucket": "my_bucket", | ||
"src_object_name": "dataset/wildtime/arxiv.hdf5", | ||
"num_outputs": 172 | ||
} |
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,5 @@ | ||
{ | ||
"dataset_name": "CLEAR10", | ||
"num_inputs": 50176, | ||
"num_outputs": 11 | ||
} |
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,5 @@ | ||
{ | ||
"dataset_name": "CLEAR100", | ||
"num_inputs": 50176, | ||
"num_outputs": 100 | ||
} |
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,4 @@ | ||
{ | ||
"dataset_name": "DomainNet", | ||
"num_outputs": 345 | ||
} |
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,7 @@ | ||
{ | ||
"dataset_name": "fmow", | ||
"src_bucket": "my_bucket", | ||
"src_object_name": "dataset/wildtime/fmow.hdf5", | ||
"num_inputs": 150528, | ||
"num_outputs": 62 | ||
} |
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,6 @@ | ||
{ | ||
"dataset_name": "huffpost", | ||
"src_bucket": "my_bucket", | ||
"src_object_name": "dataset/wildtime/huffpost.hdf5", | ||
"num_outputs": 11 | ||
} |
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,4 @@ | ||
{ | ||
"dataset_name": "MultiText", | ||
"num_outputs": 33 | ||
} |
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,7 @@ | ||
{ | ||
"dataset_name": "yearbook", | ||
"src_bucket": "my_bucket", | ||
"src_object_name": "dataset/wildtime/yearbook.hdf5", | ||
"num_inputs": 1024, | ||
"num_outputs": 2 | ||
} |
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,6 @@ | ||
{ | ||
"scenario": "arxiv-16updates.json", | ||
"model": "bert.json", | ||
"updater": "fine-tuning-arxiv.json", | ||
"dataset": "arxiv.json" | ||
} |
6 changes: 6 additions & 0 deletions
6
benchmarks/experiment_configs/fine-tuning-clear10-vitb16.json
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,6 @@ | ||
{ | ||
"scenario": "clear10-vit-b16-10updates.json", | ||
"model": "vit-b16.json", | ||
"updater": "fine-tuning-clear-vit-b16.json", | ||
"dataset": "clear10.json" | ||
} |
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,6 @@ | ||
{ | ||
"scenario": "clear10-10updates.json", | ||
"model": "resnet18.json", | ||
"updater": "fine-tuning-clear.json", | ||
"dataset": "clear10.json" | ||
} |
6 changes: 6 additions & 0 deletions
6
benchmarks/experiment_configs/fine-tuning-clear100-vitb16.json
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,6 @@ | ||
{ | ||
"scenario": "clear100-vit-b16-11updates.json", | ||
"model": "vit-b16.json", | ||
"updater": "fine-tuning-clear-vit-b16.json", | ||
"dataset": "clear100.json" | ||
} |
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,6 @@ | ||
{ | ||
"scenario": "clear100-11updates.json", | ||
"model": "resnet18.json", | ||
"updater": "fine-tuning-clear.json", | ||
"dataset": "clear100.json" | ||
} |
6 changes: 6 additions & 0 deletions
6
benchmarks/experiment_configs/fine-tuning-domainnet-vitb16.json
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,6 @@ | ||
{ | ||
"scenario": "domainnet-vit-b16-6updates.json", | ||
"model": "vit-b16.json", | ||
"updater": "fine-tuning-domainnet.json", | ||
"dataset": "domainnet.json" | ||
} |
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,6 @@ | ||
{ | ||
"scenario": "domainnet-6updates.json", | ||
"model": "resnet18.json", | ||
"updater": "fine-tuning-domainnet.json", | ||
"dataset": "domainnet.json" | ||
} |
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,6 @@ | ||
{ | ||
"scenario": "fmow-vit-b16-16updates.json", | ||
"model": "vit-b16.json", | ||
"updater": "fine-tuning-fmow.json", | ||
"dataset": "fmow.json" | ||
} |
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,6 @@ | ||
{ | ||
"scenario": "fmow-16updates.json", | ||
"model": "resnet18.json", | ||
"updater": "fine-tuning-fmow.json", | ||
"dataset": "fmow.json" | ||
} |
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,6 @@ | ||
{ | ||
"scenario": "huffpost-7updates.json", | ||
"model": "bert.json", | ||
"updater": "fine-tuning-huffpost.json", | ||
"dataset": "huffpost.json" | ||
} |
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,6 @@ | ||
{ | ||
"scenario": "multitext-4updates.json", | ||
"model": "bert.json", | ||
"updater": "fine-tuning-multitext.json", | ||
"dataset": "multitext.json" | ||
} |
6 changes: 6 additions & 0 deletions
6
benchmarks/experiment_configs/fine-tuning-yearbook-vitb16.json
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,6 @@ | ||
{ | ||
"scenario": "yearbook-vit-b16-17updates.json", | ||
"model": "vit-b16.json", | ||
"updater": "fine-tuning-yearbook.json", | ||
"dataset": "yearbook.json" | ||
} |
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,6 @@ | ||
{ | ||
"scenario": "yearbook-17updates.json", | ||
"model": "resnet18-cifar.json", | ||
"updater": "fine-tuning-yearbook.json", | ||
"dataset": "yearbook.json" | ||
} |
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,6 @@ | ||
{ | ||
"scenario": "arxiv-16updates.json", | ||
"model": "bert.json", | ||
"updater": "joint-arxiv.json", | ||
"dataset": "arxiv.json" | ||
} |
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,6 @@ | ||
{ | ||
"scenario": "cifar100-ci-10updates.json", | ||
"model": "vit-b16.json", | ||
"updater": "joint-cifar100.json", | ||
"dataset": "cifar100.json" | ||
} |
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,6 @@ | ||
{ | ||
"scenario": "clear10-vit-b16-10updates.json", | ||
"model": "vit-b16.json", | ||
"updater": "joint-clear-vit-b16.json", | ||
"dataset": "clear10.json" | ||
} |
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,6 @@ | ||
{ | ||
"scenario": "clear10-10updates.json", | ||
"model": "resnet18.json", | ||
"updater": "joint-clear.json", | ||
"dataset": "clear10.json" | ||
} |
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,6 @@ | ||
{ | ||
"scenario": "clear100-vit-b16-11updates.json", | ||
"model": "vit-b16.json", | ||
"updater": "joint-clear-vit-b16.json", | ||
"dataset": "clear100.json" | ||
} |
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,6 @@ | ||
{ | ||
"scenario": "clear100-11updates.json", | ||
"model": "resnet18.json", | ||
"updater": "joint-clear.json", | ||
"dataset": "clear100.json" | ||
} |
Oops, something went wrong.