feat(pt): add group_property training for labels defined over multiple frames #17593
Workflow file for this run
This file contains hidden or 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: Build and upload to PyPI | |
| on: | |
| push: | |
| branches-ignore: | |
| - "gh-readonly-queue/**" | |
| - "copilot/**" | |
| - "dependabot/**" | |
| - "pre-commit-ci-update-config" | |
| tags: | |
| - "v*" | |
| pull_request: | |
| merge_group: | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.ref || github.run_id }} | |
| cancel-in-progress: true | |
| jobs: | |
| build_wheels: | |
| name: Build wheels for cp${{ matrix.python }}-${{ matrix.platform_id }} | |
| runs-on: ${{ matrix.os }} | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| include: | |
| # linux-64 | |
| - os: ubuntu-latest | |
| python: 311 | |
| platform_id: manylinux_x86_64 | |
| dp_variant: cuda | |
| cuda_version: 12.8 | |
| # macos-x86-64 | |
| - os: macos-15-intel | |
| python: 311 | |
| platform_id: macosx_x86_64 | |
| dp_variant: cpu | |
| # macos-arm64 | |
| - os: macos-14 | |
| python: 311 | |
| platform_id: macosx_arm64 | |
| dp_variant: cpu | |
| # win-64 | |
| - os: windows-2022 | |
| python: 311 | |
| platform_id: win_amd64 | |
| dp_variant: cpu | |
| # linux-aarch64 | |
| - os: ubuntu-24.04-arm | |
| python: 310 | |
| platform_id: manylinux_aarch64 | |
| dp_variant: cpu | |
| steps: | |
| - uses: actions/checkout@v7 | |
| with: | |
| # https://github.com/pypa/setuptools_scm/issues/480 | |
| fetch-depth: 0 | |
| - name: Install uv | |
| uses: astral-sh/setup-uv@c771a70e6277c0a99b617c7a806ffedaca235ff9 # v9.0.0 | |
| with: | |
| version: "0.12.0" | |
| if: runner.os != 'Linux' | |
| - name: Build wheels | |
| uses: pypa/cibuildwheel@v4.2 | |
| env: | |
| CIBW_BUILD_VERBOSITY: 1 | |
| CIBW_ARCHS: all | |
| CIBW_BUILD: cp${{ matrix.python }}-${{ matrix.platform_id }} | |
| DP_VARIANT: ${{ matrix.dp_variant }} | |
| CUDA_VERSION: ${{ matrix.cuda_version }} | |
| DP_PKG_NAME: ${{ matrix.dp_pkg_name }} | |
| CIBW_BUILD_FRONTEND: "build[uv]" | |
| # uv defaults to 50 concurrent downloads, which can exhaust the | |
| # macOS runner's socket buffers while installing wheel test extras. | |
| UV_CONCURRENT_DOWNLOADS: ${{ startsWith(matrix.platform_id, 'macosx_') && '8' || '50' }} | |
| - uses: actions/upload-artifact@v7 | |
| with: | |
| name: cibw-cp${{ matrix.python }}-${{ matrix.platform_id }}-cu${{ matrix.cuda_version }}-${{ strategy.job-index }} | |
| path: ./wheelhouse/*.whl | |
| build_sdist: | |
| name: Build source distribution | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v7 | |
| with: | |
| fetch-depth: 0 | |
| - name: Build sdist | |
| run: pipx run uv tool run --with build[uv] --from build python -m build --installer uv --sdist | |
| - uses: actions/upload-artifact@v7 | |
| with: | |
| name: cibw-sdist | |
| path: dist/*.tar.gz | |
| upload_pypi: | |
| needs: [build_wheels, build_sdist] | |
| runs-on: ubuntu-latest | |
| permissions: | |
| # IMPORTANT: this permission is mandatory for trusted publishing | |
| id-token: write | |
| if: github.event_name == 'push' && startsWith(github.event.ref, 'refs/tags/v') | |
| steps: | |
| - uses: actions/download-artifact@v8 | |
| with: | |
| pattern: cibw-* | |
| path: dist | |
| merge-multiple: true | |
| - uses: pypa/gh-action-pypi-publish@release/v1 | |
| build_docker: | |
| # use the already built wheels to build docker | |
| needs: [build_wheels] | |
| runs-on: ubuntu-latest | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| include: | |
| - variant: "" | |
| cuda_version: "12" | |
| steps: | |
| - name: Free Disk Space (Ubuntu) | |
| uses: insightsengineering/disk-space-reclaimer@v1 | |
| with: | |
| tools-cache: true | |
| android: true | |
| dotnet: true | |
| haskell: true | |
| large-packages: true | |
| swap-storage: true | |
| docker-images: true | |
| - uses: actions/checkout@v7 | |
| - uses: actions/download-artifact@v8 | |
| with: | |
| path: source/install/docker/dist | |
| pattern: cibw-*-manylinux_x86_64-cu${{ matrix.cuda_version }}* | |
| merge-multiple: true | |
| - name: Log in to the Container registry | |
| uses: docker/login-action@v4 | |
| with: | |
| registry: ghcr.io | |
| username: ${{ github.actor }} | |
| password: ${{ secrets.GITHUB_TOKEN }} | |
| - name: Extract metadata (tags, labels) for Docker | |
| id: meta | |
| uses: docker/metadata-action@v6 | |
| with: | |
| images: ghcr.io/deepmodeling/deepmd-kit | |
| - name: Build and push Docker image | |
| uses: docker/build-push-action@v7 | |
| with: | |
| context: source/install/docker | |
| push: ${{ github.repository_owner == 'deepmodeling' && github.event_name == 'push' && github.actor != 'dependabot[bot]' }} | |
| tags: ${{ steps.meta.outputs.tags }}${{ matrix.variant }} | |
| labels: ${{ steps.meta.outputs.labels }} | |
| build-args: | | |
| VARIANT=${{ matrix.variant }} | |
| CUDA_VERSION=${{ matrix.cuda_version }} | |
| build_pypi_index: | |
| needs: [build_wheels, build_sdist] | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/download-artifact@v8 | |
| with: | |
| path: dist/packages | |
| pattern: cibw-* | |
| merge-multiple: true | |
| - uses: actions/setup-python@v7 | |
| name: Install Python | |
| with: | |
| python-version: "3.11" | |
| - run: pip install dumb-pypi | |
| - run: | | |
| ls dist/packages > package_list.txt | |
| dumb-pypi --output-dir dist --packages-url ../../packages --package-list package_list.txt --title "DeePMD-kit Developed Packages" | |
| - name: Upload Pages artifact | |
| uses: actions/upload-pages-artifact@v5 | |
| with: | |
| path: dist | |
| deploy_pypi_index: | |
| needs: build_pypi_index | |
| permissions: | |
| pages: write | |
| id-token: write | |
| environment: | |
| name: github-pages | |
| url: ${{ steps.deployment.outputs.page_url }} | |
| runs-on: ubuntu-latest | |
| if: github.event_name == 'push' && github.ref == 'refs/heads/master' && github.repository_owner == 'deepmodeling' | |
| steps: | |
| - name: Deploy to GitHub Pages | |
| id: deployment | |
| uses: actions/deploy-pages@v5 | |
| pass: | |
| name: Pass testing build wheels | |
| needs: [build_wheels, build_sdist, build_docker, build_pypi_index] | |
| runs-on: ubuntu-slim | |
| if: always() | |
| steps: | |
| - name: Decide whether the needed jobs succeeded or failed | |
| uses: re-actors/alls-green@release/v1 | |
| with: | |
| jobs: ${{ toJSON(needs) }} |