forked from boettiger-lab/approx-model-or-approx-soln
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' of https://github.com/boettiger-lab/caribou-rl
- Loading branch information
Showing
38 changed files
with
833 additions
and
5,152 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 |
---|---|---|
@@ -0,0 +1,44 @@ | ||
name: Pytest unit/integration | ||
|
||
on: | ||
pull_request: | ||
push: | ||
branches: | ||
- main | ||
|
||
# Use bash by default in all jobs | ||
defaults: | ||
run: | ||
shell: bash | ||
|
||
jobs: | ||
build-test: | ||
name: Test Run (${{ matrix.python-version }}, ${{ matrix.os }}) | ||
runs-on: ${{ matrix.os }} | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
os: ["ubuntu-latest"] | ||
# os: ["ubuntu-latest", "macos-latest", "windows-latest"] | ||
python-version: ["3.10", "3.11"] | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
- name: Set up Python ${{ matrix.python-version }} | ||
uses: actions/setup-python@v4 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
- name: Install dependencies | ||
run: | | ||
python -m pip install --upgrade pip | ||
python -m pip install nox | ||
- name: List installed packages | ||
run: pip list | ||
- name: Run tests with pytest & nox | ||
run: | | ||
nox -s test-${{ matrix.python-version }} | ||
# Codecov is only free for open source / public repos. Not really needed anyway | ||
# - name: Upload coverage to Codecov | ||
# if: ${{ matrix.os == 'ubuntu-latest' && matrix.python-version == '3.10'}} | ||
# uses: codecov/codecov-action@v3 | ||
|
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 |
---|---|---|
|
@@ -135,5 +135,8 @@ dmypy.json | |
# cache | ||
venv/ | ||
*.gz | ||
*.zip | ||
|
||
manuscript/*.pdf | ||
|
||
|
||
manuscript/*.pdf |
This file was deleted.
Oops, something went wrong.
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,11 @@ | ||
# stable-baselines3 configuration | ||
|
||
algo: "PPO" | ||
env_id: "Caribou-v0" | ||
n_envs: 12 | ||
tensorboard: "/home/rstudio/logs" | ||
total_timesteps: 6000000 | ||
config: {} | ||
use_sde: True | ||
id: "1" | ||
repo: "cboettig/rl-ecology" |
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,30 @@ | ||
asm: | ||
env: rl4fisheries.asm.Asm | ||
run: PPO | ||
stop: | ||
time_total_s: 24000 | ||
config: | ||
lambda: 0.95 | ||
kl_coeff: 0.5 | ||
clip_param: 0.2 | ||
vf_clip_param: 400.0 | ||
entropy_coeff: 0.0001 | ||
rollout_fragment_length: auto | ||
num_sgd_iter: 10 | ||
num_envs_per_worker: 24 | ||
min_time_s_per_iteration: 360 | ||
lr: 0.0003 | ||
|
||
# Run with Learner- and RLModule API (new stack). | ||
_enable_learner_api: true | ||
_enable_rl_module_api: true | ||
# Use N Learner worker on the GPU | ||
num_learner_workers: 2 | ||
num_gpus_per_learner_worker: 1 | ||
num_gpus: 0 # No GPU needed for driver. | ||
# Since we are using learner workers, the driver process does not need | ||
# a CPU in particular. | ||
num_cpus_for_local_worker: 1 | ||
# Need to unset this b/c we are using the RLModule API, which | ||
# provides exploration control via the RLModule's `forward_exploration` method. | ||
exploration_config: {} |
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,11 @@ | ||
# stable-baselines3 configuration | ||
|
||
algo: "TQC" | ||
env_id: "Caribou-v0" | ||
n_envs: 12 | ||
tensorboard: "/home/rstudio/logs" | ||
total_timesteps: 6000000 | ||
config: {} | ||
use_sde: True | ||
id: "1" | ||
repo: "cboettig/rl-ecology" |
Large diffs are not rendered by default.
Oops, something went wrong.
Oops, something went wrong.