Fix ValueError in concatenation of result_by_req_id
with zero-dimensional arrays, when there are 1-length arrays in the inference result.
#108
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
name: pre-commit & pytest | |
on: | |
pull_request: | |
push: | |
branches: [main] | |
pull_request_review: | |
types: [submitted] | |
jobs: | |
pre-commit: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-python@v4 | |
with: | |
python-version: '3.10' | |
- name: Get pip cache dir | |
id: pip-cache | |
run: | | |
echo "dir=$(pip cache dir)" >> $GITHUB_OUTPUT | |
- name: pip/pre-commit cache | |
uses: actions/cache@v3 | |
with: | |
path: | | |
${{ steps.pip-cache.outputs.dir }} | |
~/.cache/pre-commit | |
key: ${{ runner.os }}-pip-pre-commit-${{ hashFiles('**/.pre-commit-config.yaml') }} | |
restore-keys: | | |
${{ runner.os }}-pip-pre-commit | |
- name: pre-commit | |
run: | | |
pip install -U pre-commit | |
pre-commit install --install-hooks | |
pre-commit run -a | |
pytest: | |
runs-on: ubuntu-latest | |
needs: pre-commit | |
container: | |
image: nvcr.io/nvidia/tritonserver:23.08-pyt-python-py3 | |
options: | |
--shm-size=1g | |
--user=root | |
steps: | |
- uses: actions/checkout@v3 | |
- name: test bash | |
env: | |
TRITON_HOST: localhost | |
TRITON_HTTP: 8000 | |
TRITON_GRPC: 8001 | |
TRITON_RETRIES: 2 | |
TRITON_CLIENT_TIMEOUT: 1 | |
run: | | |
tritonserver --model-repo=$GITHUB_WORKSPACE/model_repository & | |
pip install .[tests] | |
sleep 3 | |
curl -v ${TRITON_HOST}:${TRITON_HTTP}/v2/health/ready | |
coverage run --source=tritony -m pytest | |
- name: Upload coverage data to coveralls.io | |
run: coveralls --service=github | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
COVERALLS_PARALLEL: true | |
coveralls: | |
name: Indicate completion to coveralls.io | |
needs: pytest | |
runs-on: ubuntu-latest | |
container: python:3-slim | |
steps: | |
- name: Finished | |
run: | | |
pip3 install --upgrade coveralls | |
coveralls --service=github --finish | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |