Skip to content

Commit

Permalink
Merge pull request #331 from GATEOverflow/master
Browse files Browse the repository at this point in the history
Added a github action for updating checksums, update PTD for inference v5.0
araghun authored Jan 14, 2025

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
2 parents c7bdb2f + 2f75bed commit 65eedd4
Showing 5 changed files with 63 additions and 8 deletions.
5 changes: 2 additions & 3 deletions .github/workflows/inference_power_workflow.yaml
Original file line number Diff line number Diff line change
@@ -25,8 +25,7 @@ jobs:
- name: Install dependencies
run: |
python3 -m pip install --upgrade pip
python3 -m pip install cmind
cm pull repo mlcommons@ck
python3 -m pip install cm4mlops
cm run script --quiet --tags=get,sys-utils-cm
- name: Start power server
@@ -35,4 +34,4 @@ jobs:
- name: Test CM Script for MLPerf Inference ResNet50 with power
run: |
cm run script --tags=run,mlperf,inference,generate-run-cmds,_performance-only,_short --submitter="cTuning" --model=resnet50 --backend=onnxruntime --device=cpu --scenario=Offline --test_query_count=5 --precision=fp32 --quiet --power=yes
cm run script --tags=run,mlperf,inference,generate-run-cmds,_performance-only,_short --submitter="MLCommons" --model=resnet50 --backend=onnxruntime --device=cpu --scenario=Offline --test_query_count=5 --precision=fp32 --quiet --power=yes
2 changes: 1 addition & 1 deletion .github/workflows/python_compliance.yaml
Original file line number Diff line number Diff line change
@@ -15,7 +15,7 @@ jobs:
strategy:
fail-fast: false
matrix:
python-version: [3.7, 3.8, 3.9]
python-version: [3.8, 3.9]
on: [ubuntu-latest, windows-latest]

steps:
56 changes: 56 additions & 0 deletions .github/workflows/update_checksums.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
name: Update checksums
on:
push:
branches:
- master
paths:
- 'compliance/**'
- '.github/workflows/update_checksums.yml'
- '__init__.py'
- 'client.py'
- 'lib/__init__.py'
- 'lib/client.py'
- 'lib/common.py'
- 'lib/external/__init__.py'
- 'lib/external/ntplib.py'
- 'lib/server.py'
- 'lib/source_hashes.py'
- 'lib/summary.py'
- 'lib/time_sync.py'
- 'server.py'
- 'tests/unit/__init__.py'
- 'tests/unit/test_server.py'
- 'tests/unit/test_source_hashes.py'

jobs:
update_checksums:
name: Check Python
runs-on: "${{ matrix.on }}"
strategy:
fail-fast: false
matrix:
python-version: [3.9]
on: [ubuntu-latest]

steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}

- name: Update the source checksums
run: |
python3 compliance/helper/update_sources_checksum.py
git config --global user.name "${GITHUB_ACTOR}"
git config --global user.email "${GITHUB_ACTOR}@users.noreply.github.com"
git add compliance/sources_checksums.json
HAS_CHANGES=$(git diff --staged --name-only)
if [ ${#HAS_CHANGES} -gt 0 ]; then
# Commit changes
git commit -am '[Automated Commit] Update checksums'
git push
fi
4 changes: 2 additions & 2 deletions compliance/check.py
Original file line number Diff line number Diff line change
@@ -39,7 +39,7 @@ class CheckerWarning(Exception):
pass


SUPPORTED_VERSION = ["1.10.0"]
SUPPORTED_VERSION = ["1.11.1"]
SUPPORTED_MODEL = {
"YokogawaWT210": 8,
"YokogawaWT500": 35,
@@ -214,7 +214,7 @@ def get_ptd_answer(command: str) -> str:

assert (
version in SUPPORTED_VERSION
), f"PTD version {version!r} is not supported. Supported versions are 1.10.0"
), f"PTD version {version!r} is not supported. Supported versions are {SUPPORTED_VERSION}"
assert (
power_meter_model in SUPPORTED_MODEL.keys()
), f"Power meter {power_meter_model!r} is not supported. Only {', '.join(SUPPORTED_MODEL.keys())} are supported."
4 changes: 2 additions & 2 deletions compliance/sources_checksums.json
Original file line number Diff line number Diff line change
@@ -7,9 +7,9 @@
"lib/common.py": "611d8b29633d331eb19c9455ea3b5fa3284ed6df",
"lib/external/__init__.py": "da39a3ee5e6b4b0d3255bfef95601890afd80709",
"lib/external/ntplib.py": "4da8f970656505a40483206ef2b5d3dd5e81711d",
"lib/server.py": "99303c836c683aa9017ec565104e636161d02acb",
"lib/server.py": "9bc9a3b6b9b716520658ac175913bcbbdb354336",
"lib/source_hashes.py": "60a2e02193209e8d392803326208d5466342da18",
"lib/summary.py": "aa92f0a3f975eecd44d3c0cd0236342ccc9f941d",
"lib/summary.py": "602a9fedfa503e5544d27ab3b0067f235047efc3",
"lib/time_sync.py": "80894ef2389e540781ff78de94db16aa4203a14e",
"server.py": "c3f90f2f7eeb4db30727556d0c815ebc89b3d28b",
"tests/unit/__init__.py": "da39a3ee5e6b4b0d3255bfef95601890afd80709",

0 comments on commit 65eedd4

Please sign in to comment.