Skip to content

Commit

Permalink
Merge pull request #476 from rhdong/rhdong/test-ci
Browse files Browse the repository at this point in the history
[TEST CI]
  • Loading branch information
MoFHeka authored Nov 13, 2024
2 parents 4799949 + 27c0561 commit 3946328
Show file tree
Hide file tree
Showing 2 changed files with 64 additions and 2 deletions.
64 changes: 63 additions & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,8 @@ jobs:
py-version: '3.8'
- tf-version: '2.16.2'
py-version: '3.8'
- tf-version: '2.16.2'
cpu: 'x86'
- os: 'macos-14'
cpu: 'x86'
- os: 'ubuntu-20.04'
Expand Down Expand Up @@ -111,9 +113,69 @@ jobs:
with:
name: ${{ runner.os }}-${{ matrix.py-version }}-tf${{ matrix.tf-version }}-${{ steps.device.outputs.value }}-${{ matrix.cpu }}-wheel
path: wheelhouse
release-wheel-cpu-tf216:
name: Build release wheels for CPU TF2.16
strategy:
matrix:
# TODO: add back 'windows-latest' when it can be compiled.
os: ['ubuntu-20.04' ]
py-version: [ '3.9', '3.10', '3.11' ]
tf-version: [ '2.16.2' ]
tf-need-cuda: [ '0' ]
cpu: [ 'x86']
fail-fast: false
runs-on: [self-hosted, Linux, X64]
steps:
- name: clear cache folder
run: rm -rf /usr/share/dotnet /opt/ghc "/usr/local/share/boost"
- uses: actions/github-script@0.3.0
id: author-date
with:
github-token: ${{secrets.GITHUB_TOKEN}}
script: |
const commit_details = await github.git.getCommit({owner: context.repo.owner, repo: context.repo.repo, commit_sha: context.sha});
return commit_details.data.author.date
- if: matrix.tf-version < '2.15.1'
shell: bash
run: echo "SKIP_CUSTOM_OP_TESTS=--skip-custom-ops" >> $GITHUB_ENV
- if: github.event_name == 'push'
shell: bash
run: echo "NIGHTLY_FLAG=--nightly" >> $GITHUB_ENV
- uses: actions/checkout@v2
- uses: actions/setup-python@v2
with:
python-version: ${{ matrix.py-version }}
- name: Setup Bazel
# Ubuntu bazel is run inside of the docker image
if: matrix.os != 'ubuntu-20.04'
run: bash tools/install_deps/install_bazelisk.sh ./
- name: Build wheels
env:
OS: ${{ runner.os }}
PY_VERSION: ${{ matrix.py-version }}
TF_VERSION: ${{ matrix.tf-version }}
TF_NEED_CUDA: ${{ matrix.tf-need-cuda }}
NIGHTLY_TIME: ${{ steps.author-date.outputs.result }}
CPU: ${{ matrix.cpu }}
shell: bash
run: |
if [[ "$TF_VERSION" =~ ^2\.(11|12|13|14|15|16)\.[0-9]$ ]] ; then
export HOROVOD_VERSION="0.28.1"
fi
bash .github/workflows/make_wheel_${OS}_${CPU}.sh
- uses: haya14busa/action-cond@v1
id: device
with:
cond: ${{ matrix.tf-need-cuda == '1' }}
if_true: "gpu"
if_false: "cpu"
- uses: actions/upload-artifact@v4
with:
name: ${{ runner.os }}-${{ matrix.py-version }}-tf${{ matrix.tf-version }}-${{ steps.device.outputs.value }}-${{ matrix.cpu }}-wheel
path: wheelhouse
release-wheel-gpu:
name: Build release wheels for GPU
needs: [release-wheel-cpu, test-with-bazel]
needs: [release-wheel-cpu, release-wheel-cpu-tf216, test-with-bazel]
strategy:
matrix:
# TODO: add back 'windows-latest' when it can be compiled.
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -298,7 +298,7 @@ sess_config.gpu_options.allow_growth = True
| 0.1.0 | 2.4.1 | r2.4 | GCC 7.3.1 | - | - | - |

Serving TFRA-enable models by custom ops in TensorFlow Serving.

```sh
## If enable GPU OPs
export SERVING_WITH_GPU=1
Expand Down

0 comments on commit 3946328

Please sign in to comment.