Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update test durations #6656

Open
wants to merge 6 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
56,564 changes: 28,459 additions & 28,105 deletions .github/durations/core_tests_durations.json

Large diffs are not rendered by default.

30,902 changes: 15,672 additions & 15,230 deletions .github/durations/jax_tests_durations.json

Large diffs are not rendered by default.

8,910 changes: 4,511 additions & 4,399 deletions .github/durations/tf_tests_durations.json

Large diffs are not rendered by default.

5 changes: 4 additions & 1 deletion .github/workflows/docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,9 @@ on:
- reopened
- synchronize
- ready_for_review
# Scheduled trigger on Wednesdays at 3:00am UTC
schedule:
- cron: "0 3 * * 3"

permissions: write-all

Expand Down Expand Up @@ -63,7 +66,7 @@ jobs:
path: doc.txt

upload-stable-deps:
if: github.event.pull_request.draft == false
if: github.event_name == 'schedule'
needs:
- determine_runner
- sphinx
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/interface-dependency-versions.yml
Original file line number Diff line number Diff line change
Expand Up @@ -63,11 +63,11 @@ jobs:

- name: Nightly Catalyst Version
id: catalyst
run: echo "nightly=--extra-index-url https://test.pypi.org/simple/ PennyLane-Catalyst --pre" >> $GITHUB_OUTPUT
run: echo "nightly=--index https://test.pypi.org/simple/ --prerelease=allow --upgrade-package PennyLane-Catalyst PennyLane-Catalyst" >> $GITHUB_OUTPUT

- name: PennyLane-Lightning Latest Version
id: pennylane-lightning
run: echo "latest=-i https://test.pypi.org/simple/ PennyLane-Lightning --pre --upgrade" >> $GITHUB_OUTPUT
run: echo "latest=--index https://test.pypi.org/simple/ --prerelease=allow --upgrade-package PennyLane-Lightning PennyLane-Lightning" >> $GITHUB_OUTPUT

outputs:
jax-version: jax==${{ steps.jax.outputs.version }} jaxlib==${{ steps.jax.outputs.version }}
Expand Down
13 changes: 3 additions & 10 deletions .github/workflows/interface-unit-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -465,18 +465,12 @@ jobs:
pytest_markers: external
pytest_additional_args: -W ${{ inputs.python_warning_level }} ${{ inputs.python_warning_level != 'default' && '--continue-on-collection-errors' || '' }}
additional_pip_packages: |
pyzx matplotlib stim quimb==1.8.4 mitiq ply optax
pyzx matplotlib stim quimb mitiq ply optax scipy-openblas32>=0.3.26
git+https://github.com/PennyLaneAI/pennylane-qiskit.git@master
${{ needs.default-dependency-versions.outputs.jax-version }}
${{ needs.default-dependency-versions.outputs.tensorflow-version }}
${{ inputs.additional_python_packages }}

# This is required during the release process when the latest released version of
# catalyst requires the latest version of pennylane that is about to be released.
# Installing catalyst after pennylane to make sure that the latest catalyst is used.
additional_pip_packages_post: |
${{ needs.default-dependency-versions.outputs.catalyst-nightly }}
${{ needs.default-dependency-versions.outputs.pennylane-lightning-latest }}
${{ inputs.additional_python_packages }}

requirements_file: ${{ github.event_name == 'schedule' && strategy.job-index == 0 && 'external.txt' || '' }}

Expand Down Expand Up @@ -548,13 +542,12 @@ jobs:
branch: ${{ inputs.branch }}
coverage_artifact_name: qchem-coverage
python_version: ${{ matrix.python-version }}

additional_pip_packages_post: ${{ needs.default-dependency-versions.outputs.pennylane-lightning-latest }}
pytest_coverage_flags: ${{ inputs.pytest_coverage_flags }}
pytest_markers: qchem
pytest_additional_args: -W ${{ inputs.python_warning_level }} ${{ inputs.python_warning_level != 'default' && '--continue-on-collection-errors' || '' }}
additional_pip_packages: |
openfermionpyscf basis-set-exchange
openfermionpyscf basis-set-exchange geometric scikit-learn
${{ inputs.additional_python_packages }}

gradients-tests:
Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/tests-labs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -61,9 +61,12 @@ jobs:
job_runner_name: ${{ needs.determine_runner.outputs.runner_group }}
branch: ${{ github.ref }}
coverage_artifact_name: labs-coverage
additional_os_packages: openmpi-bin openmpi-doc libopenmpi-dev
pytest_additional_args: --import-mode=importlib
pytest_coverage_flags: --cov-config=pennylane/labs/.coveragerc --cov=pennylane/labs --cov-append --cov-report=term-missing --cov-report=xml --no-flaky-report --tb=native
python_version: '3.10'
pytest_test_directory: pennylane/labs/tests
additional_pip_packages: |
geometric mpi4py h5py basis_set_exchange pyscf
geometric mpi4py h5py basis-set-exchange pyscf optax
${{ needs.default-dependency-versions.outputs.jax-version }}
6 changes: 3 additions & 3 deletions .github/workflows/trigger_benchmarks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,9 +47,9 @@ jobs:
username: user
});
const userPermissions = data.user.permissions;
const permission = userPermissions.admin || userPermissions.maintain;
const permission = userPermissions.admin || userPermissions.maintain || (userPermissions.write || userPermissions.push);

console.log(`User '${user}' has admin/maintain access => ${permission}`);
console.log(`User '${user}' has admin/maintain/write access => ${permission}`);

return permission;

Expand Down Expand Up @@ -85,7 +85,7 @@ jobs:
}

- name: React to original comment indicating webhook sent
if: steps.comment_user.outputs.result == 'true'
if: steps.comment_body.outputs.triggers_benchmark == 'true' && steps.comment_user.outputs.result == 'true'
uses: actions/github-script@v7
env:
REPO_OWNER: ${{ steps.repo_info.outputs.REPO_OWNER }}
Expand Down
54 changes: 44 additions & 10 deletions .github/workflows/unit-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,11 @@ on:
description: Name of the artifact file that will contain the coverage file for codevoc
required: true
type: string
uv_version:
description: The version of uv (docs.astral.sh/uv/) to use to install dependencies
required: false
type: string
default: 0.5.5
job_runner_name:
description: The name of the runner to use for the job
required: false
Expand Down Expand Up @@ -77,6 +82,14 @@ on:
required: false
type: string
default: ''
additional_os_packages:
description: Additional packages to install. Values will be passed to apt-get install {value}
required: false
type: string
default: ''

env:
UV_SYSTEM_PYTHON: 1

jobs:
test:
Expand All @@ -90,19 +103,40 @@ jobs:
ref: ${{ inputs.branch }}
fetch-depth: ${{ inputs.checkout_fetch_depth }}
repository: PennyLaneAI/pennylane


- name: Install uv
uses: astral-sh/setup-uv@v4
with:
version: ${{ inputs.uv_version }}
enable-cache: true
cache-dependency-glob: 'requirements-*.txt'

- name: Setup Python
uses: actions/setup-python@v5
with:
python-version: '${{ inputs.python_version }}'

- name: Install additional os packages
if: inputs.additional_os_packages != ''
env:
ADDITIONAL_OS_PACKAGES: ${{ inputs.additional_os_packages }}
run: |
while IFS= read -r line; do
if [ ! -z "$line" ]; then
echo ''
echo "Now installing -> sudo apt-get install -y $line"
echo ''

sudo apt-get install -y $line
fi
done <<< "$ADDITIONAL_OS_PACKAGES"

- name: Upgrade PIP and install wheel
run: pip install --upgrade pip && pip install wheel --upgrade
run: uv pip install --upgrade pip wheel

- name: Install PennyLane dependencies
run: |
pip install -r requirements-ci.txt --upgrade
pip install -r requirements-dev.txt --upgrade
uv pip install -r requirements-ci.txt -r requirements-dev.txt --upgrade

- name: Install additional PIP packages (Pre-PennyLane)
shell: bash
Expand All @@ -113,18 +147,18 @@ jobs:
while IFS= read -r line; do
if [ ! -z "$line" ]; then
echo ''
echo "Now installing -> pip install $line"
echo "Now installing -> uv pip install $line"
echo ''

pip install $line
uv pip install $line
fi
done <<< "$ADDITIONAL_PIP_PACKAGES"

- name: Install PennyLane
shell: bash
run: |
python setup.py bdist_wheel
pip install dist/PennyLane*.whl
uv build --wheel
uv pip install dist/PennyLane*.whl

- name: Install additional PIP packages (Post PennyLane Install)
shell: bash
Expand All @@ -135,10 +169,10 @@ jobs:
while IFS= read -r line; do
if [ ! -z "$line" ]; then
echo ''
echo "Now installing -> pip install $line"
echo "Now installing -> uv pip install $line"
echo ''

pip install $line
uv pip install $line
fi
done <<< "$ADDITIONAL_PIP_PACKAGES"

Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,12 +35,12 @@

<p align="center">
The definitive open-source framework for quantum programming. Built by researchers, for research.
<img src="https://raw.githubusercontent.com/PennyLaneAI/pennylane/master/doc/_static/header.png#gh-light-mode-only" width="700px">
<img src="https://raw.githubusercontent.com/PennyLaneAI/pennylane/master/doc/_static/readme/pl-logo-lightmode.png#gh-light-mode-only" width="700px">
<!--
Use a relative import for the dark mode image. When loading on PyPI, this
will fail automatically and show nothing.
-->
<img src="./doc/_static/header-dark-mode.png#gh-dark-mode-only" width="700px" onerror="this.style.display='none'" alt=""/>
<img src="./doc/_static/readme/pl-logo-darkmode.png#gh-dark-mode-only" width="700px" onerror="this.style.display='none'" alt=""/>
</p>

## Key Features
Expand Down
Binary file added doc/_static/opengraph.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added doc/_static/readme/pl-logo-darkmode.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added doc/_static/readme/pl-logo-lightmode.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added doc/_static/templates/subroutines/gqsp.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion doc/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@
"site_url": "https://docs.pennylane.ai/",
"line_color": "#03b2ff",
}
ogp_image = "_static/header-tall.png"
ogp_image = "_static/opengraph.png"


# The base URL with a proper language and version.
Expand Down
Loading