|
a |
|
b/internal/scripts/README.md |
|
|
1 |
# Scripts for commonly performed bionemo-framework actions. |
|
|
2 |
|
|
|
3 |
## First Time Setup |
|
|
4 |
|
|
|
5 |
After cloning the repository, you need to run the setup script **first**: |
|
|
6 |
|
|
|
7 |
```bash |
|
|
8 |
./internal/scripts/setup_env_file.sh |
|
|
9 |
``` |
|
|
10 |
|
|
|
11 |
This will return an exit code of 1 on a first time run. |
|
|
12 |
|
|
|
13 |
## Release Image Building |
|
|
14 |
|
|
|
15 |
To build the release image, run the following script: |
|
|
16 |
|
|
|
17 |
```bash |
|
|
18 |
DOCKER_BUILDKIT=1 ./ci/scripts/build_docker_image.sh \ |
|
|
19 |
-regular-docker-builder \ |
|
|
20 |
-image-name "nvcr.io/nvidian/cvai_bnmo_trng/bionemo:bionemo2-$(git rev-parse HEAD)" |
|
|
21 |
``` |
|
|
22 |
|
|
|
23 |
## Development Image Building |
|
|
24 |
|
|
|
25 |
To build the development image, run the following script: |
|
|
26 |
|
|
|
27 |
```bash |
|
|
28 |
./internal/scripts/build_dev_image.sh |
|
|
29 |
``` |
|
|
30 |
|
|
|
31 |
## Interactive Shell in Development Image |
|
|
32 |
|
|
|
33 |
After building the development image, you can start a container from it and open a bash shell in it by executing: |
|
|
34 |
|
|
|
35 |
```bash |
|
|
36 |
./internal/scripts/run_dev.sh |
|
|
37 |
``` |
|
|
38 |
|
|
|
39 |
## Testing Locally |
|
|
40 |
|
|
|
41 |
Inside the development container, run `./ci/scripts/static_checks.sh` to validate that code changes will pass the code |
|
|
42 |
formatting and license checks run during CI. In addition, run the longer `./ci/scripts/run_pytest.sh` script to run unit |
|
|
43 |
tests for all sub-packages. |