dvc: commit experiment 87872e8f72649f4b604bd2a565090b1a8300dfd750bc15… #25
Workflow file for this run
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
name: train-model | |
on: | |
push: | |
paths: | |
- "data/**" | |
- "stages/**" | |
- "params.yaml" | |
- "dvc.*" | |
jobs: | |
train-model: | |
runs-on: ubuntu-latest | |
environment: cloud | |
permissions: | |
contents: read | |
id-token: write | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
ref: ${{ github.event.pull_request.head.sha }} | |
- uses: iterative/setup-cml@v1 | |
- uses: actions/setup-python@v2 | |
with: | |
python-version: "3.9" | |
# This block is using Iterative Sandbox AWS User | |
# Comment it out if using your own credentials | |
- uses: aws-actions/configure-aws-credentials@v1 | |
with: | |
aws-region: us-east-1 | |
role-to-assume: arn:aws:iam::342840881361:role/SandboxUser | |
- name: Setup Git User | |
run: cml ci | |
env: | |
REPO_TOKEN: ${{ secrets.PERSONAL_ACCESS_TOKEN }} | |
- name: Train model | |
env: | |
REPO_TOKEN: ${{ secrets.PERSONAL_ACCESS_TOKEN }} | |
# Uncomment the below if using your own credentials | |
# AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }} | |
# AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }} | |
# AWS_SESSION_TOKEN: ${{ secrets.AWS_SESSION_TOKEN }} | |
run: | | |
pip install -r requirements.txt | |
dvc pull | |
dvc repro | |
dvc push | |
# Create CML report | |
echo "## Metrics" >> report.md | |
dvc metrics show --md >> report.md | |
echo "## Confusion Matrix" >> report.md | |
cml publish eval_plots/cm.png --md >> report.md | |
cml send-comment report.md |