Skip to content

Commit

Permalink
Merge pull request #62 from arjunsuresh/mlperf-inference
Browse files Browse the repository at this point in the history
Fix for setup.py
  • Loading branch information
arjunsuresh authored Jun 13, 2024
2 parents cbc984e + bd1732d commit bf8fa6c
Show file tree
Hide file tree
Showing 6 changed files with 26 additions and 13 deletions.
8 changes: 6 additions & 2 deletions .github/workflows/test-cm4mlops-wheel.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,13 @@ on:
jobs:
build:
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, ubuntu-20.04]
python-version: ['3.8', '3.12']
python-version: ['3.8', '3.11', '3.12']
exclude:
- os: ubuntu-latest
python-version: "3.8"

runs-on: ${{ matrix.os }}

Expand All @@ -36,4 +40,4 @@ jobs:
run: |
python3 -m venv cm
source cm/bin/activate
python3 -m pip install .
python3 -m pip install . -v
6 changes: 3 additions & 3 deletions .github/workflows/test-mlperf-inference-resnet50.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,11 +26,11 @@ jobs:
exclude:
- backend: tf
implementation: cpp
- os: windows-latest
- os: macos-latest
backend: tf
- os: windows-latest
python-version: "3.9"
- os: macos-latest
python-version: "3.9"
- os: windows-latest

steps:
- uses: actions/checkout@v3
Expand Down
2 changes: 2 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
[build-system]
requires = ["setuptools>=60", "wheel", "cmind @ git+https://[email protected]/mlcommons/ck.git@a4c6a7b477af5f1e7099c55f5468a47854adaa6c#egg=cmind&subdirectory=cm"]
5 changes: 4 additions & 1 deletion script/build-dockerfile/dockerinfo.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
"package-manager-update-cmd": "apt-get update -y",
"package-manager-get-cmd": "apt-get install -y",
"packages": [
"python3", "python3-pip", "git", "sudo", "wget"
"python3", "python3-pip", "git", "sudo", "wget", "python3-venv"
],
"versions": {
"18.04": {
Expand All @@ -39,6 +39,9 @@
},
"23.04": {
"FROM": "ubuntu:23.04"
},
"24.04": {
"FROM": "ubuntu:24.04"
}
}
},
Expand Down
2 changes: 1 addition & 1 deletion script/get-sys-utils-cm/run-ubuntu.sh
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ ${CM_SUDO} ${CM_APT_TOOL} update && \
libncurses5 \
libjpeg9-dev \
unzip \
libgl1-mesa-glx \
libgl1 \
zlib1g-dev

# Install Python deps though preference is to install them
Expand Down
16 changes: 10 additions & 6 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,7 @@ class CustomInstallCommand(install):
def run(self):
self.get_sys_platform()
self.install_system_packages()
packages = [ "cmind @ git+https://[email protected]/mlcommons/ck.git@a4c6a7b477af5f1e7099c55f5468a47854adaa6c#egg=cmind-2.3.1.1&subdirectory=cm", "giturlparse", "requests", "pyyaml", "setuptools" ]
subprocess.check_call(
[sys.executable, '-m', 'pip', 'install'] + packages
)

# Call the standard run method
install.run(self)

Expand All @@ -36,7 +33,7 @@ def install_system_packages(self):
if not curl_status:
packages.append("curl")

name='virtualenv'
name='venv'

if name in sys.modules:
pass #nothing needed
Expand Down Expand Up @@ -113,7 +110,14 @@ def get_sys_platform(self):
name='cm4mlops',
version='0.1',
packages=[],
install_requires=["wheel"],
install_requires=[
"setuptools>=60",
"wheel",
"cmind",
"giturlparse",
"requests",
"pyyaml"
],
cmdclass={
'install': CustomInstallCommand,
},
Expand Down

0 comments on commit bf8fa6c

Please sign in to comment.