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

Add job to try and build gpu package in CI #775

Merged
merged 30 commits into from
Aug 6, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
30 commits
Select commit Hold shift + click to select a range
94c8ea5
Add job to try and build gpu package in CI
mtreinish Jun 1, 2020
e9126be
Bump cibuildwheel version used
mtreinish Jun 1, 2020
8072d23
Remove sudo usage from job
mtreinish Jun 1, 2020
93fa92a
Add yum-utils to container
mtreinish Jun 1, 2020
1b2a49d
Switch to azure so we can locally test wheels
mtreinish Jun 1, 2020
c7aafe2
Enable setting thrust backend via env var
mtreinish Jun 1, 2020
c6df7cc
Use CUDA not cuda
mtreinish Jun 1, 2020
32325e5
Add AER_CUDA_ARCH env var
mtreinish Jun 4, 2020
5a3091d
Add more versions to wheel job
mtreinish Jun 5, 2020
45414e7
Reduce number of CUDA architectures
mtreinish Jun 5, 2020
a2b3b57
Split wheel job up across 2 jobs for different python versions
mtreinish Jun 8, 2020
73b5c5d
Merge branch 'master' into add-gpu-jobs
mtreinish Jun 29, 2020
0e3d561
Pivot to github actions for the 6 hour jobs
mtreinish Jun 29, 2020
303c36f
Add back missing 'jobs' key
mtreinish Jun 29, 2020
20c207c
Fix gha syntax
mtreinish Jun 29, 2020
57d1e35
Merge branch 'master' into add-gpu-jobs
mtreinish Jul 29, 2020
d108fda
Add back push trigger for testing
mtreinish Jul 29, 2020
90daaaa
Unskip py37 and py38 builds
mtreinish Jul 29, 2020
48b73f9
Publish to twine after build and only run on tags
mtreinish Jul 30, 2020
9febe0c
Merge branch 'master' into add-gpu-jobs
mtreinish Jul 30, 2020
3815c70
Add missing quotes
mtreinish Jul 31, 2020
a2835ce
Merge branch 'master' into add-gpu-jobs
mtreinish Aug 3, 2020
5efe168
Merge branch 'master' into add-gpu-jobs
chriseclectic Aug 5, 2020
d4722a5
Switch to CUDA 10.1 instead of 10.2
mtreinish Aug 5, 2020
efbf60b
DNM: test wheel builds
mtreinish Aug 5, 2020
094808f
Try local cuda 10.1 installer instead
mtreinish Aug 5, 2020
6122528
Remove invalid version cap
mtreinish Aug 5, 2020
d89d732
Update .github/workflows/main.yml
chriseclectic Aug 5, 2020
ad90243
Update .github/workflows/main.yml
chriseclectic Aug 6, 2020
44b3f63
Merge branch 'master' into add-gpu-jobs
chriseclectic Aug 6, 2020
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
40 changes: 40 additions & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
name: Build
on: [push, pull_request]
# push:
# tags:
# - '*'
jobs:
build:
name: Build qiskit-aer-gpu wheels
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-python@v2
name: Install Python
with:
python-version: '3.7'
- name: Install cibuildwheel
run: |
python -m pip install cibuildwheel==1.5.5
- name: Build wheels
env:
CIBW_BEFORE_ALL: "yum install -y yum-utils wget && wget https://developer.download.nvidia.com/compute/cuda/10.1/Prod/local_installers/cuda-repo-rhel6-10-1-local-10.1.243-418.87.00-1.0-1.x86_64.rpm && rpm -i cuda-repo-rhel6-10-1-local-10.1.243-418.87.00-1.0-1.x86_64.rpm && yum clean all && yum -y install cuda-10-1"
CIBW_BEFORE_BUILD: "pip install -U Cython pip virtualenv pybind11"
CIBW_SKIP: "cp27-* cp34-* *-manylinux_i686 pp*"
CIBW_MANYLINUX_X86_64_IMAGE: "manylinux2010"
CIBW_MANYLINUX_I686_IMAGE: "manylinux2010"
CIBW_ENVIRONMENT: QISKIT_AER_PACKAGE_NAME=qiskit-aer-gpu AER_THRUST_BACKEND=CUDA
CIBW_TEST_COMMAND: "python3 {project}/tools/verify_wheels.py"
CIBW_TEST_REQUIRES: "git+https://github.com/Qiskit/qiskit-terra.git"
run: |
python -m cibuildwheel --output-dir wheelhouse
- uses: actions/upload-artifact@v2
with:
path: ./wheelhouse/*.whl
# - name: Publish Wheels
# env:
# TWINE_PASSWORD: ${{ secrets.TWINE_PASSWORD }}
# TWINE_USERNAME: qiskit
# run : |
# pip install -U twine
# twine upload wheelhouse/*
8 changes: 7 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,13 @@ endif()

# GPU support through Thrust library (CPU fallbacks)
# Defaults to TRUE, but if no Thrust backend has been defined, will set to FALSE
set(AER_THRUST_SUPPORTED TRUE)
if(NOT DEFINED AER_THRUST_BACKEND)
set(AER_THRUST_BACKEND $ENV{AER_THRUST_BACKEND})
if(DEFINED AER_THRUST_BACKEND)
set(AER_THRUST_SUPPORTED TRUE)
endif()
endif()

if(AER_THRUST_SUPPORTED)
if(AER_THRUST_BACKEND STREQUAL "CUDA")
message(STATUS "Thrust library: Looking for CUDA backend...")
Expand Down
4 changes: 3 additions & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@
import sys
import inspect

PACKAGE_NAME = os.getenv('QISKIT_AER_PACKAGE_NAME', 'qiskit-aer')

try:
from conans import client
except ImportError:
Expand Down Expand Up @@ -69,7 +71,7 @@
README = readme_file.read()

setup(
name='qiskit-aer',
name=PACKAGE_NAME,
version=VERSION,
packages=setuptools.find_namespace_packages(include=['qiskit.*']),
cmake_source_dir='.',
Expand Down