-
Notifications
You must be signed in to change notification settings - Fork 93
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* new CI configuration * Set up CI with Azure Pipelines [skip ci] * install numpy in cibuildwheel * add pyproject.toml * upgrade vmImage * update the build python versions * remove the pytest * move the wheel build files * enable sdist setup.py as well. * use git command line * Update wheels.yml for Azure Pipelines * disable the pypy package for macos; * fix the external repo code tag * fix the ctest problem * fix the unicode 8217. * fix the locale base test
- Loading branch information
Showing
14 changed files
with
166 additions
and
66 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
jobs: | ||
- job: linux | ||
pool: {vmImage: 'ubuntu-latest'} | ||
steps: | ||
- task: UsePythonVersion@0 | ||
- bash: | | ||
set -o errexit | ||
python3 -m pip install --upgrade pip | ||
pip3 install cibuildwheel==2.1.2 | ||
displayName: Install dependencies | ||
- bash: cibuildwheel --output-dir wheelhouse . | ||
displayName: Build wheels | ||
- task: PublishBuildArtifacts@1 | ||
inputs: {pathtoPublish: 'wheelhouse'} | ||
|
||
- job: macos | ||
pool: {vmImage: 'macOS-latest'} | ||
variables: | ||
CIBW_ARCHS_MACOS: "x86_64 universal2 arm64" | ||
# Skip trying to test arm64 builds on Intel Macs | ||
# CIBW_TEST_SKIP: "*-macosx_arm64 *-macosx_universal2:arm64" | ||
# Disable building PyPy wheels | ||
CIBW_SKIP: pp* | ||
|
||
steps: | ||
- task: UsePythonVersion@0 | ||
- bash: | | ||
set -o errexit | ||
python3 -m pip install --upgrade pip | ||
python3 -m pip install cibuildwheel==2.1.2 | ||
displayName: Install dependencies | ||
- bash: cibuildwheel --output-dir wheelhouse . | ||
displayName: Build wheels | ||
- task: PublishBuildArtifacts@1 | ||
inputs: {pathtoPublish: wheelhouse} | ||
|
||
# - job: windows | ||
# pool: {vmImage: 'windows-latest'} | ||
# steps: | ||
# - task: UsePythonVersion@0 | ||
# - bash: | | ||
# set -o errexit | ||
# python -m pip install --upgrade pip | ||
# pip install cibuildwheel==2.1.2 | ||
# displayName: Install dependencies | ||
# - bash: cibuildwheel --output-dir wheelhouse . | ||
# displayName: Build wheels | ||
# - task: PublishBuildArtifacts@1 | ||
# inputs: {pathtoPublish: 'wheelhouse'} |
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,15 @@ | ||
prune ci_build | ||
prune docs | ||
exclude *.bat | ||
exclude *.yaml | ||
exclude *.git* | ||
include *.txt | ||
global-include *.def | ||
recursive-include cmake *.* | ||
recursive-include includes *.* | ||
recursive-include operators *.* | ||
recursive-include pyop *.* | ||
recursive-include shared *.* | ||
prune ci_build | ||
prune docs | ||
prune test | ||
prune _subbuild | ||
prune out | ||
exclude *.bat | ||
exclude *.yaml | ||
exclude *.git* |
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
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,19 @@ | ||
FetchContent_Declare( | ||
sentencepieceproject | ||
spm | ||
GIT_REPOSITORY https://github.com/google/sentencepiece.git | ||
GIT_TAG v0.1.96 | ||
) | ||
# spm is abbr. of sentencepiece to meet the MAX_PATH compiling requirement on Windows | ||
FetchContent_GetProperties(spm) | ||
|
||
FetchContent_GetProperties(sentencepieceproject) | ||
|
||
if(NOT sentencepieceproject_POPULATED) | ||
FetchContent_Populate(sentencepieceproject) | ||
add_subdirectory(${sentencepieceproject_SOURCE_DIR} ${sentencepieceproject_BINARY_DIR} EXCLUDE_FROM_ALL) | ||
if(NOT spm_POPULATED) | ||
FetchContent_Populate(spm) | ||
add_subdirectory(${spm_SOURCE_DIR} ${spm_BINARY_DIR} EXCLUDE_FROM_ALL) | ||
endif() | ||
|
||
set(sentencepieceproject_INCLUDE_DIRS | ||
${sentencepieceproject_SOURCE_DIR}/third_party/protobuf-lite | ||
${sentencepieceproject_SOURCE_DIR}/src/builtin_pb | ||
${sentencepieceproject_SOURCE_DIR}/third_party | ||
${sentencepieceproject_SOURCE_DIR}/src | ||
set(spm_INCLUDE_DIRS | ||
${spm_SOURCE_DIR}/third_party/protobuf-lite | ||
${spm_SOURCE_DIR}/src/builtin_pb | ||
${spm_SOURCE_DIR}/third_party | ||
${spm_SOURCE_DIR}/src | ||
) |
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
# Copyright (c) Microsoft Corporation. All rights reserved. | ||
# Licensed under the MIT License. See License.txt in the project root for | ||
# license information. | ||
############################################################################### | ||
|
||
__version__ = "0.4.0" |
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
[project] | ||
# since onnxruntime havn't supported Python 3.10 yet | ||
requires-python = "<3.10" | ||
|
||
[build-system] | ||
# Minimum requirements for the build system to execute. | ||
requires = ["setuptools", "wheel", "numpy>=1.18.5"] # PEP 508 specifications. |
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
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