Skip to content

Commit 13c708e

Browse files
authored
Merge pull request #2738 from bettinaheim/staging/0.10.0
0.10.0 package updates and dependent changes
2 parents 3ac999f + 306e993 commit 13c708e

File tree

65 files changed

+705
-916
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

65 files changed

+705
-916
lines changed

.github/workflows/ci.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -234,7 +234,7 @@ jobs:
234234
strategy:
235235
matrix:
236236
platform: [amd64, arm64]
237-
python_version: ['3.12'] # FIXME: add '3.10' back
237+
python_version: ['3.10', '3.12']
238238
cuda_version: ["11.8", "12.0"]
239239
fail-fast: false
240240
uses: ./.github/workflows/python_wheels.yml
@@ -255,7 +255,7 @@ jobs:
255255
uses: ./.github/workflows/python_metapackages.yml
256256
with:
257257
cudaq_version: ${{ needs.python_wheels.outputs.cudaq_version }}
258-
python_versions: "['3.12']" # fixme: reenable 3.10
258+
python_versions: "['3.10', '3.12']"
259259
cuda_versions: "['', '11.8', '12.0']"
260260
wheel_artifacts: 'pycudaq-*'
261261

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
nvidia-mgpu-repo: cuda-quantum/cuquantum-mgpu.git
2-
nvidia-mgpu-commit: de32bf2abae42f118a0da36be0066296d76b0dbc
2+
nvidia-mgpu-commit: ddfaacf2ffd7dc1a9a4333e06474b213887d437c

.github/workflows/deployments.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -370,7 +370,7 @@ jobs:
370370
cuda_version=${{ matrix.cuda_version }}
371371
base_image=${{ fromJson(needs.config.outputs.json).image_hash[format('{0}-gcc11', matrix.platform)] }}
372372
ompidev_image=${{ fromJson(needs.config.outputs.json).image_hash[format('{0}-cu{1}-ompi', matrix.platform, matrix.cuda_version)] }}
373-
${{ matrix.cuda_version != '11.8' && 'cuda_packages=cuda-cudart cuda-nvrtc cuda-compiler libcublas-dev libcusolver libnvjitlink' || '' }}
373+
${{ matrix.cuda_version != '11.8' && 'cuda_packages=cuda-cudart cuda-nvrtc cuda-compiler libcublas-dev libcurand-dev libcusolver libnvjitlink' || '' }}
374374
registry_cache_from: ${{ needs.metadata.outputs.cache_base }}
375375
update_registry_cache: ${{ needs.metadata.outputs.cache_target }}
376376
environment: ${{ needs.metadata.outputs.environment }}

.github/workflows/docker_images.yml

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -165,7 +165,7 @@ jobs:
165165
driver-opts: |
166166
network=host
167167
image=moby/buildkit:v0.19.0
168-
168+
169169
- name: Build Open MPI
170170
id: docker_build
171171
uses: docker/build-push-action@v5
@@ -483,6 +483,9 @@ jobs:
483483
484484
platform_tag=${{ needs.metadata.outputs.platform_tag }}
485485
cuda_major=`echo ${{ inputs.cuda_version }} | cut -d . -f1`
486+
if [ "$cuda_major" == "11" ]; then
487+
deprecation_notice="**Note**: Support for CUDA 11 will be removed in future releases. Please update to CUDA 12."
488+
fi
486489
image_tag=${platform_tag:+$platform_tag-}${cuda_major:+cu${cuda_major}-}
487490
if ${{ github.event.pull_request.number != '' }} || [ -n "$(echo ${{ github.ref_name }} | grep pull-request/)" ]; then
488491
pr_number=`echo ${{ github.ref_name }} | grep -o [0-9]*`
@@ -502,6 +505,7 @@ jobs:
502505
echo "base_image=$base_image" >> $GITHUB_OUTPUT
503506
echo "devdeps_image=$devdeps_image" >> $GITHUB_OUTPUT
504507
echo "dev_image_name=$dev_image_name" >> $GITHUB_OUTPUT
508+
echo "deprecation_notice=$deprecation_notice" >> $GITHUB_OUTPUT
505509
506510
if ${{ inputs.environment == '' }}; then
507511
tar_archive=/tmp/cuda-quantum.tar
@@ -602,6 +606,7 @@ jobs:
602606
cudaqdev_image=${{ steps.prereqs.outputs.dev_image_name }}@${{ steps.release_build.outputs.digest }}
603607
base_image=${{ steps.prereqs.outputs.base_image }}
604608
release_version=${{ steps.prereqs.outputs.image_tag }}
609+
deprecation_notice=${{ steps.prereqs.outputs.deprecation_notice }}
605610
tags: ${{ steps.cudaq_metadata.outputs.tags }}
606611
labels: ${{ steps.cudaq_metadata.outputs.labels }}
607612
platforms: ${{ inputs.platforms }}
@@ -719,7 +724,7 @@ jobs:
719724
# Unfortunately, we need to install cuquantum for docs generation to work properly,
720725
# since using mock imports in the autodocs configuration doesn't work properly.
721726
# See also https://github.com/sphinx-doc/sphinx/issues/11211.
722-
docker exec cuda-quantum-dev bash -c "python3 -m pip cache purge && python3 -m pip install cuquantum-python-cu12~=24.11"
727+
docker exec cuda-quantum-dev bash -c "python3 -m pip install cuquantum-python-cu12~=25.03"
723728
724729
(docker exec cuda-quantum-dev bash -c "export $docs_version && bash scripts/build_docs.sh" && built=true) || built=false
725730
if $built; then docker cp cuda-quantum-dev:"/usr/local/cudaq/docs/." docs; \
@@ -820,7 +825,7 @@ jobs:
820825
docker cp docs/notebook_validation.py cuda-quantum:"/home/cudaq/notebook_validation.py"
821826
# In containers without GPU support, UCX does not work properly since it is configured to work with GPU-support.
822827
# Hence, don't enforce UCX when running these tests.
823-
docker exec cuda-quantum bash -c "python3 -m pip cache purge && python3 -m pip install pandas scipy pandas seaborn 'h5py<3.11' contfrac"
828+
docker exec cuda-quantum bash -c "python3 -m pip install pandas scipy pandas seaborn 'h5py<3.11' contfrac"
824829
(docker exec cuda-quantum bash -c "unset OMPI_MCA_pml && set -o pipefail && bash validate_container.sh | tee /tmp/validation.out") && passed=true || passed=false
825830
docker cp cuda-quantum:"/tmp/validation.out" /tmp/validation.out
826831
docker stop cuda-quantum

.github/workflows/publishing.yml

Lines changed: 19 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -682,7 +682,7 @@ jobs:
682682
echo "docker_output=type=local,dest=/tmp/wheels" >> $GITHUB_OUTPUT
683683
env:
684684
GH_TOKEN: ${{ secrets.REPO_BOT_ACCESS_TOKEN }}
685-
685+
686686
- name: Log in to DockerHub
687687
uses: docker/login-action@v3
688688
with:
@@ -942,6 +942,7 @@ jobs:
942942
cuda_version_suffix="$(echo ${{ matrix.cuda_version }} | tr . -)"
943943
apt-get update && apt-get install -y --no-install-recommends \
944944
libcublas-$cuda_version_suffix \
945+
libcurand-$cuda_version_suffix \
945946
cuda-cudart-$cuda_version_suffix \
946947
libcusolver-$cuda_version_suffix \
947948
cuda-nvrtc-$cuda_version_suffix
@@ -1000,15 +1001,17 @@ jobs:
10001001
wheel_validation_piponly:
10011002
name: Wheel validation, pip only
10021003
needs: [assets, cudaq_wheels, cudaq_metapackages]
1003-
runs-on: linux-amd64-gpu-v100-latest-1
10041004
permissions:
10051005
contents: read
10061006

10071007
strategy:
10081008
matrix:
1009+
platform: ['amd64-gpu-v100', 'arm64-gpu-a100']
10091010
cuda_major: ['', '11', '12']
10101011
fail-fast: false
10111012

1013+
runs-on: linux-${{ matrix.platform }}-latest-1
1014+
10121015
container:
10131016
image: ubuntu:22.04
10141017
options: --user root
@@ -1036,11 +1039,11 @@ jobs:
10361039
name: ${{ needs.cudaq_metapackages.outputs.artifact_name }}
10371040
path: /tmp/packages
10381041

1039-
- name: Run x86 validation
1042+
- name: Run basic validation
10401043
shell: bash
10411044
run: |
1042-
# These simple steps are only expected to work for x86 and only for
1043-
# targets and test cases that don't require MPI.
1045+
# These simple steps are only expected to work for
1046+
# test cases that don't require MPI.
10441047
# Create clean python3 environment.
10451048
apt-get update && apt-get install -y --no-install-recommends python3 python3-pip
10461049
mkdir -p /tmp/packages && mv /tmp/wheels/* /tmp/packages && rmdir /tmp/wheels
@@ -1124,7 +1127,7 @@ jobs:
11241127
pattern: '*-wheels'
11251128
path: /tmp/wheels
11261129
merge-multiple: true
1127-
1130+
11281131
- name: Load metapackage
11291132
uses: actions/download-artifact@v4
11301133
with:
@@ -1211,10 +1214,16 @@ jobs:
12111214
for installer in `find installers/ -type f -not -name '*.whl'`; do
12121215
mv -v "$installer" "$(basename -- "$installer")"
12131216
done
1214-
for dir in `ls wheelhouse/`; do
1215-
mv -v "wheelhouse/$dir"/* wheelhouse/ && rmdir "wheelhouse/$dir"
1217+
# A single wheelhouse.zip file is too big. Split it up by platform.
1218+
platforms=$(ls wheelhouse | cut -d- -f1 | sort | uniq)
1219+
for p in $platforms; do
1220+
mkdir wheelhouse-${p}
1221+
for fulldir in wheelhouse/${p}-*; do
1222+
dir=$(basename $fulldir)
1223+
mv -v "wheelhouse/$dir"/* wheelhouse-${p}/ && rmdir "wheelhouse/$dir"
1224+
done
1225+
zip -r wheelhouse-${p}.zip wheelhouse-${p}
12161226
done
1217-
zip -r wheelhouse.zip wheelhouse
12181227
zip -r metapackages.zip metapackages
12191228
12201229
release_id=${{ inputs.assets_from_run || github.run_id }}
@@ -1231,7 +1240,7 @@ jobs:
12311240
--target $github_commit --draft $prerelease \
12321241
--generate-notes --notes-start-tag $latest_tag --notes "$rel_notes"
12331242
gh release upload $release_id -R ${{ github.repository }} install_cuda_quantum* --clobber
1234-
gh release upload $release_id -R ${{ github.repository }} wheelhouse.zip --clobber
1243+
gh release upload $release_id -R ${{ github.repository }} wheelhouse-*.zip --clobber
12351244
gh release upload $release_id -R ${{ github.repository }} metapackages.zip --clobber
12361245
gh release edit $release_id -R ${{ github.repository }} \
12371246
--title "$release_title" --tag $version $prerelease # --draft=false

.github/workflows/python_metapackages.yml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -59,9 +59,10 @@ jobs:
5959
echo "Creating README.md for cudaq package"
6060
package_name=cudaq
6161
cuda_version_requirement="11.x (where x \>= 8) or 12.x"
62-
cuda_version_conda=11.8.0 # only used as example in the install script
62+
cuda_version_conda=12.4.0 # only used as example in the install script
63+
deprecation_notice="**Note**: Support for CUDA 11 will be removed in future releases. Please update to CUDA 12."
6364
cat python/README.md.in > python/metapackages/README.md
64-
for variable in package_name cuda_version_requirement cuda_version_conda; do
65+
for variable in package_name cuda_version_requirement cuda_version_conda deprecation_notice; do
6566
sed -i "s/.{{[ ]*$variable[ ]*}}/${!variable}/g" python/metapackages/README.md
6667
done
6768
if [ -n "$(cat python/metapackages/README.md | grep -e '.{{.*}}')" ]; then

.github/workflows/python_wheels.yml

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -188,13 +188,6 @@ jobs:
188188
matrix:
189189
os_image: ${{ fromJSON(needs.create_test_config.outputs.json).os_images }}
190190
pip_install_flags: ['', '--user']
191-
exclude:
192-
- os_image: ubuntu:22.04
193-
pip_install_flags: '--user'
194-
- os_image: ubuntu:24.04
195-
pip_install_flags: '--user'
196-
- os_image: fedora:39
197-
pip_install_flags: ''
198191
fail-fast: false
199192

200193
steps:
@@ -257,7 +250,7 @@ jobs:
257250
echo "::error file=python_wheel.yml::Python tests failed with status $pytest_status."
258251
exit 1
259252
fi
260-
python${{ inputs.python_version }} -m pip install --user fastapi uvicorn llvmlite openfermionpyscf==0.5
253+
python${{ inputs.python_version }} -m pip install --user fastapi uvicorn llvmlite
261254
for backendTest in /tmp/tests/backends/*.py; do
262255
python${{ inputs.python_version }} -m pytest $backendTest
263256
pytest_status=$?

.github/workflows/test_in_devenv.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -215,16 +215,18 @@ jobs:
215215
-t dev_env:local -f docker/build/cudaq.dev.Dockerfile . \
216216
--build-arg base_image=$base_image
217217
218+
- name: Setup proxy cache
219+
uses: nv-gha-runners/setup-proxy-cache@main
220+
218221
- name: Build and test CUDA Quantum (Python)
219222
uses: ./.github/actions/run-in-docker
220223
with:
221224
image: dev_env:local
222225
shell: bash
223226
run: |
224227
cd $CUDAQ_REPO_ROOT
225-
pip cache purge
226228
pip install iqm_client==16.1 --user -vvv
227-
pip install . -vvv # FIXME: --user causes package hash mismatch on ubuntu...
229+
pip install . --user -vvv
228230
pyinstall_status=$?
229231
if [ ! $pyinstall_status -eq 0 ]; then
230232
echo "::error file=test_in_devenv.yml:: Pip install of CUDA Quantum failed with status $pyinstall_status."

docker/build/assets.Dockerfile

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -224,6 +224,7 @@ RUN echo "Patching up wheel using auditwheel..." && \
224224
--plat ${MANYLINUX_PLATFORM} \
225225
--exclude libcublas.so.11 \
226226
--exclude libcublasLt.so.11 \
227+
--exclude libcurand.so.10 \
227228
--exclude libcusolver.so.11 \
228229
--exclude libcutensor.so.2 \
229230
--exclude libcutensornet.so.2 \
@@ -262,7 +263,7 @@ RUN gcc_packages=$(dnf list installed "gcc*" | sed '/Installed Packages/d' | cut
262263

263264
## [Python MLIR tests]
264265
RUN cd /cuda-quantum && source scripts/configure_build.sh && \
265-
python3 -m pip install lit pytest scipy cuquantum-python-cu$(echo ${CUDA_VERSION} | cut -d . -f1)~=24.11 && \
266+
python3 -m pip install lit pytest scipy cuquantum-python-cu$(echo ${CUDA_VERSION} | cut -d . -f1)~=25.03 && \
266267
"${LLVM_INSTALL_PREFIX}/bin/llvm-lit" -v _skbuild/python/tests/mlir \
267268
--param nvqpp_site_config=_skbuild/python/tests/mlir/lit.site.cfg.py
268269
# The other tests for the Python wheel are run post-installation.
@@ -322,7 +323,8 @@ RUN . /cuda-quantum/scripts/configure_build.sh install-gcc && \
322323
dnf install -y --nobest --setopt=install_weak_deps=False \
323324
cuda-compiler-$(echo ${CUDA_VERSION} | tr . -) \
324325
cuda-cudart-devel-$(echo ${CUDA_VERSION} | tr . -) \
325-
libcublas-devel-$(echo ${CUDA_VERSION} | tr . -) && \
326+
libcublas-devel-$(echo ${CUDA_VERSION} | tr . -) \
327+
libcurand-devel-$(echo ${CUDA_VERSION} | tr . -) && \
326328
if [ $(echo $CUDA_VERSION | cut -d "." -f1) -ge 12 ]; then \
327329
dnf install -y --nobest --setopt=install_weak_deps=False \
328330
libnvjitlink-$(echo ${CUDA_VERSION} | tr . -); \

docker/build/devdeps.ext.Dockerfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,7 @@ ENV UCX_TLS=rc,cuda_copy,cuda_ipc,gdr_copy,sm
130130

131131
# Install CUDA
132132

133-
ARG cuda_packages="cuda-cudart cuda-nvrtc cuda-compiler libcublas-dev libcusolver"
133+
ARG cuda_packages="cuda-cudart cuda-nvrtc cuda-compiler libcublas-dev libcurand-dev libcusolver"
134134
RUN if [ -n "$cuda_packages" ]; then \
135135
arch_folder=$([ "$(uname -m)" == "aarch64" ] && echo sbsa || echo x86_64) \
136136
&& cuda_packages=`printf '%s\n' $cuda_packages | xargs -I {} echo {}-$(echo ${CUDA_VERSION} | tr . -)` \
@@ -164,7 +164,7 @@ ENV PATH="${CUDA_INSTALL_PREFIX}/lib64/:${CUDA_INSTALL_PREFIX}/bin:${PATH}"
164164
RUN apt-get update && apt-get install -y --no-install-recommends \
165165
python3 python3-pip && \
166166
apt-get autoremove -y && apt-get clean && rm -rf /var/lib/apt/lists/* && \
167-
python3 -m pip install cuquantum-python-cu$(echo $CUDA_VERSION | cut -d . -f1)~=24.11 && \
167+
python3 -m pip install cuquantum-python-cu$(echo $CUDA_VERSION | cut -d . -f1)~=25.03 && \
168168
if [ "$(python3 --version | grep -o [0-9\.]* | cut -d . -f -2)" != "3.10" ]; then \
169169
echo "expecting Python version 3.10"; \
170170
fi

0 commit comments

Comments
 (0)