PTQ-Level Efficiency, QAT-Level Accuracy | 训练后量化的效率,量化感知训练的精度
update cd workflow (#1151)
chen, suyue1ac2f15a674f
diff --git a/.github/workflows/manual-binary-build-publish.yml b/.github/workflows/manual-binary-build-publish.ymlindex 479707409..4ee856063 100644--- a/.github/workflows/manual-binary-build-publish.yml+++ b/.github/workflows/manual-binary-build-publish.yml@@ -11,8 +11,13 @@ on:required: truetype: stringpublish:- default: false- description: 'Publish the binary to PyPi'+ default: true+ description: 'Publish the binary'+ required: false+ type: boolean+ test_pypi:+ default: true+ description: 'Publish to TestPyPI, for test only'required: falsetype: boolean@@ -25,12 +30,12 @@ jobs:fail-fast: truesteps:- name: Checkout out Repo- uses: actions/checkout@v4+ uses: actions/checkout@v6with:ref: ${{ inputs.branch }}- name: Set up Python- uses: actions/setup-python@v2+ uses: actions/setup-python@v6with:python-version: '3.12'@@ -48,16 +53,32 @@ jobs:python setup.py sdist bdist_wheel ${{ matrix.option }}fi- - name: Publish the binary+ - name: Upload the artifacts+ uses: actions/upload-artifact@v6+ with:+ name: dist-${{ matrix.option }}+ path: dist++ - name: Publish to PyPIif: ${{ fromJSON(inputs.publish) }}env:- TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}- working-directory: ./${{ matrix.repo }}+ TWINE_USERNAME: "__token__"+ PYPI_PASSWORD: ${{ secrets.PYPI_PASSWORD }}+ TESTPYPI_PASSWORD: ${{ secrets.TESTPYPI_PASSWORD }}run: |python -m pip install --upgrade twine- # python -m twine upload dist/*+ if [ "${{ inputs.test_pypi }}" == "true" ]; then+ export TWINE_PASSWORD=${TESTPYPI_PASSWORD}+ echo "publish to TestPyPI"+ twine upload --verbose --repository testpypi dist/*+ else+ if git describe --exact-match --tags >/dev/null 2>&1; then+ export TWINE_PASSWORD=${PYPI_PASSWORD}+ echo "publish to PyPI"+ twine upload dist/*+ else+ echo "This branch is not a tag, shouldn't be uploaded into PyPI."+ fi+ fi+- - uses: actions/[email protected]- with:- name: dist-${{ matrix.option }}- path: dist