File tree Expand file tree Collapse file tree 1 file changed +5
-4
lines changed Expand file tree Collapse file tree 1 file changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -146,22 +146,23 @@ jobs:
146146 - name : Run DVC commands in container
147147 run : |
148148 mkdir model_storage
149- touch best_model_checkpoint.txt
150149 docker run --rm --gpus=all \
151150 -v model_storage:/workspace/model_storage \
152- -v best_model_checkpoint.txt:/workspace/best_model_checkpoint.txt \
153151 -e AWS_ACCESS_KEY_ID=${{ secrets.AWS_ACCESS_KEY_ID }} \
154152 -e AWS_SECRET_ACCESS_KEY=${{ secrets.AWS_SECRET_ACCESS_KEY }} \
155153 -e AWS_DEFAULT_REGION=${{ secrets.AWS_REGION }} \
156154 ${{ secrets.AWS_ECR_LOGIN_URI }}/${{ secrets.ECR_REPOSITORY_NAME }}:latest \
157155 /bin/bash -c "
158156 dvc pull -r myremote && \
159157 mkdir model_storage && \
160- dvc repro -f
158+ dvc repro -f && \
159+ cp best_model_checkpoint.txt model_storage/
161160 "
162161
163162 # # Wait a moment to ensure the container has started
164163 # sleep 5
164+
165+ ls model_storage/
165166
166167 # # Print logs from the container
167168 # docker logs $CONTAINER_ID
@@ -172,7 +173,7 @@ jobs:
172173 - name : Read best checkpoint file name
173174 id : read_checkpoint
174175 run : |
175- checkpoint_file=$(head -n 1 best_model_checkpoint.txt)
176+ checkpoint_file=$(head -n 1 model_storage/ best_model_checkpoint.txt)
176177 echo "CHECKPOINT_FILE=$checkpoint_file" >> $GITHUB_ENV
177178
178179 - name : Get latest commit ID
You can’t perform that action at this time.
0 commit comments