Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

skip passed work #3575

Open
wants to merge 14 commits into
base: develop
Choose a base branch
from
Open

skip passed work #3575

wants to merge 14 commits into from

Conversation

causten
Copy link
Collaborator

@causten causten commented Oct 30, 2024

Still testing, but the idea is to skip a passed test if the current commit hash matches is marked as passed already

Jenkinsfile Outdated
git diff
git diff-index --quiet HEAD || (echo "Generated files are different. Please run make generate and commit the changes." && exit 1)
make -j\$(nproc) all package check VERBOSE=1
#make -j\$(nproc) all package check VERBOSE=1
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should skip the entire stage including docker/cmake builds and even possibly checkout. This should probably be done in the node(name) section below, or before if possible since we are just checking a commit hash.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Even better would be to do it in(or around) the Check image stage. Set an env variable to a list of the contexes that are success, and then we can check that variable before we even allocate a node. It would also reduce the number github API calls we need to make(it would be once per build instead of once per build per stage).

Jenkinsfile Outdated
md5sum ./*.deb
echo ${GIT_COMMIT_SHA} > "${name}_PR"
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I dont think storing it locally in the workspace is useful since it wont exist on every node. Instead you should check the github commit status, something like this:

    withCredentials([string(credentialsId: "${env.migraphx_ci_creds}", variable: 'GITHUB_TOKEN')]) {
        def commit_hash = sh(script: 'git rev-parse --short HEAD', returnStdout: true).trim()
        def response = sh(
            script: """curl -H "Accept: application/vnd.github+json" \
                           -H "Authorization: token ${GITHUB_TOKEN}" \
                           https://api.github.com/repos/ROCm/AMDMIGraphX/commits/${commit_hash}/status""",
            returnStdout: true
        ).trim()
        def statuses = response.statuses
        def contextStatus = statuses.find { it.context == "Jenkins - ${variant}"
        env.COMMIT_PASSED = contextStatus != null && contextStatus.state == 'success'
    }

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

interesting, I was trying to use archieveAritfact since it would be shared across nodes, but I hadn't figured out a way to pull the file down. I like your idea and will try that

@migraphx-bot
Copy link
Collaborator

Test Batch Rate new
078757
Rate old
538898
Diff Compare
torchvision-resnet50 64 3,260.03 3,259.25 0.02%
torchvision-resnet50_fp16 64 6,978.06 6,987.98 -0.14%
torchvision-densenet121 32 2,435.35 2,435.18 0.01%
torchvision-densenet121_fp16 32 4,073.17 4,107.65 -0.84%
torchvision-inceptionv3 32 1,637.92 1,638.45 -0.03%
torchvision-inceptionv3_fp16 32 2,764.77 2,765.03 -0.01%
cadene-inceptionv4 16 776.82 776.04 0.10%
cadene-resnext64x4 16 811.14 811.47 -0.04%
slim-mobilenet 64 7,537.11 7,532.97 0.05%
slim-nasnetalarge 64 211.55 211.47 0.04%
slim-resnet50v2 64 3,505.06 3,506.08 -0.03%
bert-mrpc-onnx 8 1,151.78 1,145.67 0.53%
bert-mrpc-tf 1 461.35 464.12 -0.60%
pytorch-examples-wlang-gru 1 434.27 415.28 4.57% 🔆
pytorch-examples-wlang-lstm 1 387.14 382.85 1.12%
torchvision-resnet50_1 1 761.93 775.95 -1.81%
cadene-dpn92_1 1 406.74 403.42 0.82%
cadene-resnext101_1 1 376.14 383.63 -1.95%
onnx-taau-downsample 1 342.37 341.73 0.19%
dlrm-criteoterabyte 1 33.35 33.34 0.04%
dlrm-criteoterabyte_fp16 1 52.74 52.72 0.05%
agentmodel 1 8,473.71 8,136.83 4.14% 🔆
unet_fp16 2 58.96 58.73 0.39%
resnet50v1_fp16 1 1,001.92 968.97 3.40% 🔆
resnet50v1_int8 1 988.66 1,017.05 -2.79%
bert_base_cased_fp16 64 1,172.25 1,171.55 0.06%
bert_large_uncased_fp16 32 363.57 363.37 0.05%
bert_large_fp16 1 200.60 199.99 0.30%
distilgpt2_fp16 16 2,202.81 2,203.14 -0.02%
yolov5s 1 540.11 530.68 1.78%
tinyllama 1 43.44 43.42 0.05%
vicuna-fastchat 1 174.56 178.25 -2.07%
whisper-tiny-encoder 1 418.36 417.77 0.14%
whisper-tiny-decoder 1 437.11 435.63 0.34%

Check results before merge 🔆

@migraphx-bot
Copy link
Collaborator


     ✅ bert-mrpc-onnx: PASSED: MIGraphX meets tolerance

     ✅ bert-mrpc-tf: PASSED: MIGraphX meets tolerance

     ✅ pytorch-examples-wlang-gru: PASSED: MIGraphX meets tolerance

     ✅ pytorch-examples-wlang-lstm: PASSED: MIGraphX meets tolerance

     ✅ torchvision-resnet50_1: PASSED: MIGraphX meets tolerance

     ✅ cadene-dpn92_1: PASSED: MIGraphX meets tolerance

     ✅ cadene-resnext101_1: PASSED: MIGraphX meets tolerance

     ✅ dlrm-criteoterabyte: PASSED: MIGraphX meets tolerance

     ✅ agentmodel: PASSED: MIGraphX meets tolerance

     ✅ unet: PASSED: MIGraphX meets tolerance

     ✅ resnet50v1: PASSED: MIGraphX meets tolerance

     ✅ bert_base_cased_fp16: PASSED: MIGraphX meets tolerance

🔴bert_large_uncased_fp16: FAILED: MIGraphX is not within tolerance - check verbose output


     ✅ bert_large: PASSED: MIGraphX meets tolerance

     ✅ yolov5s: PASSED: MIGraphX meets tolerance

     ✅ tinyllama: PASSED: MIGraphX meets tolerance

     ✅ vicuna-fastchat: PASSED: MIGraphX meets tolerance

     ✅ whisper-tiny-encoder: PASSED: MIGraphX meets tolerance

     ✅ whisper-tiny-decoder: PASSED: MIGraphX meets tolerance

     ✅ distilgpt2_fp16: PASSED: MIGraphX meets tolerance

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants