-
Notifications
You must be signed in to change notification settings - Fork 1
89 lines (87 loc) · 3.26 KB
/
on-pr-with-image.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
name: On pull request workflows requiring the CNeuroMax image
on:
pull_request:
branches: [main]
jobs:
docker-build:
runs-on: self-hosted
steps:
- name: Checkout the GitHub repo
uses: actions/checkout@v4
- name: Build the tentative CNeuroMax Docker image
run: docker build -t cneuromod/cneuromax:test .
sphinx-build:
needs: docker-build
runs-on: self-hosted
steps:
- name: Checkout the GitHub repo
uses: actions/checkout@v4
- name: Build the documentation with Sphinx
run: >
docker run --rm -v ${PWD}:${PWD} -w ${PWD} cneuromod/cneuromax:test
sphinx-build -b html ./docs/ ./docs/build/
mypy:
needs: docker-build
runs-on: self-hosted
steps:
- name: Checkout the GitHub repo
uses: actions/checkout@v4
- name: Static type checking with Mypy
run: >
docker run --rm -v ${PWD}:${PWD} -w ${PWD} cneuromod/cneuromax:test
mypy --config-file=pyproject.toml cneuromax
pytest:
needs: docker-build
runs-on: self-hosted
steps:
- name: Checkout the GitHub repo
uses: actions/checkout@v4
- name: Unit testing with pytest
run: >
docker run --rm -v ${PWD}:${PWD} -w ${PWD} cneuromod/cneuromax:test
pytest --cov cneuromax
classify_mnist-mlp_cpu:
needs: docker-build
runs-on: self-hosted
steps:
- name: Checkout the GitHub repo
uses: actions/checkout@v4
- name: Create WANDB_KEY.txt file
run: echo ${{ secrets.WANDB_KEY_MLC }} > ${PWD}/WANDB_KEY.txt
- name: Runs project=classify_mnist task=mlp_cpu
run: >
docker run --privileged --gpus all --rm -e CNEUROMAX_PATH=${PWD}
-v ${PWD}:${PWD} -e PYTHONPATH=${PYTHONPATH}:${PWD}
-v /dev/shm:/dev/shm -w ${PWD} cneuromod/cneuromax:test
python3 -m cneuromax project=classify_mnist task=mlp_cpu
logger.entity=maximilienlc
classify_mnist-mlp:
needs: docker-build
runs-on: self-hosted
steps:
- name: Checkout the GitHub repo
uses: actions/checkout@v4
- name: Create WANDB_KEY.txt file
run: echo ${{ secrets.WANDB_KEY_MLC }} > ${PWD}/WANDB_KEY.txt
- name: Runs project=classify_mnist task=mlp
run: >
docker run --privileged --gpus all --rm -e CNEUROMAX_PATH=${PWD}
-v ${PWD}:${PWD} -e PYTHONPATH=${PYTHONPATH}:${PWD}
-v /dev/shm:/dev/shm -w ${PWD} cneuromod/cneuromax:test
python3 -m cneuromax project=classify_mnist task=mlp
logger.entity=maximilienlc litmodule.config.log_val_wandb=True
neuroevorl_control-acrobot:
needs: docker-build
runs-on: self-hosted
steps:
- name: Checkout the GitHub repo
uses: actions/checkout@v4
- name: Create WANDB_KEY.txt file
run: echo ${{ secrets.WANDB_KEY_MLC }} > ${PWD}/WANDB_KEY.txt
- name: Runs project=neuroevorl_control task=acrobot
run: >
docker run --privileged --gpus all --rm -e CNEUROMAX_PATH=${PWD}
-v ${PWD}:${PWD} -e PYTHONPATH=${PYTHONPATH}:${PWD}
-v /dev/shm:/dev/shm -w ${PWD} cneuromod/cneuromax:test
python3 -m cneuromax project=neuroevorl_control task=acrobot
logger.entity=maximilienlc config.total_num_gens=10