@@ -35,13 +35,21 @@ jobs:
3535 with :
3636 fetch-depth : 0
3737
38+ - name : Get merge-base commit
39+ id : merge-base
40+ run : |
41+ # Get the merge-base between current branch and main
42+ MERGE_BASE=$(git merge-base HEAD origin/main)
43+ echo "merge-base=$MERGE_BASE" >> $GITHUB_OUTPUT
44+ echo "Merge-base commit: $MERGE_BASE"
45+
3846 - name : Get changed files
3947 id : changed-files
4048 uses : step-security/changed-files@v46
4149 with :
4250 json : true
4351 matrix : true
44- base_sha : main
52+ base_sha : ${{ steps.merge-base.outputs.merge-base }}
4553 dir_names : true
4654 dir_names_max_depth : 2
4755 files : |
@@ -84,21 +92,35 @@ jobs:
8492 # Assign Docker images to the selected directories
8593 # Currently, AMPLIFY is the only folder that needs a custom base image, since we have to support both TE and
8694 # xformers-based models for golden value testing. The rest of the models use the default pytorch image.
95+
96+ # This uses a squashed version of the pytorch:25.06-py3 image, generated with `docker-squash
97+ # nvcr.io/nvidia/pytorch:25.06-py3 -t svcbionemo023/bionemo-framework:pytorch25.06-py3-squashed --output
98+ # type=registry,compression=zstd,force-compression=true,oci-mediatypes=true,compression-level=15` and pushed
99+ # to the dockerhub registry. Our github actions are able to cache image pulls from dockerhub but not nvcr, so
100+ # hopefully this cuts down slightly on CI time at the expense of having a slightly in-directed image location.
101+
87102 DIRS_WITH_IMAGES=$(echo "$DIRS" | jq -c '
88103 map({
89104 dir: .,
90105 image: (
91106 if . == "models/amplify" then
92107 "svcbionemo023/bionemo-framework:amplify-model-devcontainer-082025"
93108 else
94- "nvcr.io/nvidia/pytorch:25 .06-py3"
109+ "svcbionemo023/bionemo-framework:pytorch25 .06-py3-squashed-zstd "
95110 end
96111 )
97112 })
98113 ')
99114 echo "dirs=$DIRS_WITH_IMAGES" >> $GITHUB_OUTPUT
115+
100116 - name : Show output
101117 run : |
118+ echo "=== Changed Files Analysis ==="
119+ echo "Current branch: ${{ github.ref_name }}"
120+ echo "Merge-base commit: ${{ steps.merge-base.outputs.merge-base }}"
121+ echo "Changed files compared to merge-base:"
122+ echo '${{ steps.changed-files.outputs.all_changed_files }}' | jq -r '.[]' | sed 's/^/ - /'
123+ echo "Total changed files: $(echo '${{ steps.changed-files.outputs.all_changed_files }}' | jq '. | length')"
102124 echo '${{ toJSON(steps.changed-files.outputs) }}'
103125 echo '${{ toJSON(steps.set-dirs.outputs) }}'
104126 shell : bash
@@ -115,8 +137,12 @@ jobs:
115137 fail-fast : false
116138
117139 steps :
140+
141+ - name : Show GPU info
142+ run : nvidia-smi
118143 - name : Setup proxy cache
119144 uses : nv-gha-runners/setup-proxy-cache@main
145+
120146 - name : Checkout repository
121147 uses : actions/checkout@v4
122148 with :
@@ -125,7 +151,6 @@ jobs:
125151
126152 - name : Install dependencies
127153 working-directory : ${{ matrix.recipe.dir }}
128- #
129154 run : |
130155 if [ -f pyproject.toml ] || [ -f setup.py ]; then
131156 PIP_CONSTRAINT= pip install -e .
0 commit comments