Skip to content

Commit

Permalink
Add the mac python packaging script (#72)
Browse files Browse the repository at this point in the history
* Add pipeline for building python wheels for Windows/Linux CPU and GPU

* try enable mkldnn

* remove mklml

* Update python packaging configuration

* Try macos pywheel packaging

* Try removing mkldnn from mac build

* Use conda in mac agents

* Change to build release only

* Add the mac wheel packaging list to the packaging yaml

* Add mkldnn into mac wheels
  • Loading branch information
Raymond Yang authored and pranavsharma committed Dec 1, 2018
1 parent 3a7ecc5 commit 71ea923
Showing 1 changed file with 47 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -182,3 +182,50 @@ jobs:
filename: deactivate
continueOnError: true
condition: always()

- job: MacOS_py_Wheels
pool:
vmImage: 'macOS-10.13'
strategy:
matrix:
Python35:
python.version: '3.5'
Python36:
python.version: '3.6'

steps:
- task: CondaEnvironment@1
inputs:
createCustomEnvironment: true
environmentName: 'py$(python.version)'
packageSpecs: 'python=$(python.version)'
cleanEnvironment: true

- script: |
sudo python -m pip install numpy
sudo xcode-select --switch /Applications/Xcode_10.app/Contents/Developer
./build.sh --config Release --skip_submodule_sync --parallel --use_mkldnn --build_wheel
displayName: 'Command Line Script'
- task: CopyFiles@2
displayName: 'Copy Python Wheel to: $(Build.ArtifactStagingDirectory)'
inputs:
SourceFolder: '$(Build.SourcesDirectory)'
Contents: '**/dist/onnxruntime-*.whl'
TargetFolder: '$(Build.ArtifactStagingDirectory)'

- task: PublishBuildArtifacts@1
displayName: 'Publish Artifact: ONNXRuntime python wheel'
inputs:
ArtifactName: onnxruntime

- script: 'sudo rm -rf $(Agent.BuildDirectory)'
displayName: 'Clean build folders/files'
condition: always()

- task: CmdLine@1
displayName: 'Deactivating Conda Environment'
inputs:
filename: deactivate
continueOnError: true
condition: always()

0 comments on commit 71ea923

Please sign in to comment.