Improve GeoOptMetricsTable and remove duplicate scatter plot controls… #2219
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: Tests | |
| on: | |
| push: | |
| branches: [main] | |
| pull_request: | |
| branches: [main] | |
| release: | |
| types: [published] | |
| workflow_dispatch: | |
| inputs: | |
| task: | |
| type: choice | |
| options: [tests, release] | |
| default: tests | |
| description: Only run tests or release a new version of pymatgen to PyPI after tests pass. | |
| workflow_call: | |
| concurrency: | |
| # Cancel only on same PR number | |
| group: ${{ github.workflow }}-pr-${{ github.event.pull_request.number }} | |
| cancel-in-progress: true | |
| jobs: | |
| pytest: | |
| strategy: | |
| matrix: | |
| os: [ubuntu-latest, windows-latest] | |
| uses: janosh/workflows/.github/workflows/pytest.yml@main | |
| with: | |
| os: ${{ matrix.os }} | |
| python-version: '3.11' | |
| # TODO remove main branch install of pymatviz after next release | |
| install-cmd: | | |
| uv pip install -e .[test,symmetry] --system | |
| uv pip install git+https://github.com/janosh/pymatviz --system | |
| vitest: | |
| uses: janosh/workflows/.github/workflows/deno-test.yml@main | |
| with: | |
| working-directory: site | |
| test-cmd: npx vitest run | |
| deno-version: 2.3.7 # https://github.com/denoland/deno/issues/29968 | |
| scripts: | |
| runs-on: ubuntu-latest | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| script: | |
| - scripts/evals/discovery.py | |
| # TODO run_all.py was commented out during removal of WBM energy preds from version control. consider partially reinstating with on-the-fly downloaded or mock WBM energy preds | |
| # - scripts/model_figs/run_all.py | |
| steps: | |
| - name: Check out repository | |
| uses: actions/checkout@v4 | |
| - name: Set up Python | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: '3.11' | |
| - name: Install package and dependencies | |
| run: pip install -e .[plots] | |
| - name: Run script | |
| run: python ${{ matrix.script }} | |
| env: | |
| WANDB_API_KEY: ${{ secrets.WANDB_API_KEY }} |