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

[Quantum] Submit jobs directly to service, Phase 1 #5290

Merged
merged 72 commits into from
Feb 6, 2023

Conversation

warren-jones
Copy link
Contributor

@warren-jones warren-jones commented Aug 30, 2022

Submit jobs directly to the Quantum service data-plane layer from the CLI. This will support submission of QIR and pass-through jobs. Minimal support is included for QIO jobs that only require gzip compression, not protobuf input.

Four new command parameters were added:
--job-input-file
--job-input-format
--job-output-format
--entry-point

Additional parameters can be passed using --job-params


Related commands

az quantum job submit
az quantum execute
az quantum run

General Guidelines

This checklist is used to make sure that common guidelines for a pull request are followed.

  • Have you run azdev style <YOUR_EXT> locally? (pip install azdev required)
  • Have you run python scripts/ci/test_index.py -q locally?

@ghost ghost added the Auto-Assign Auto assign by bot label Aug 30, 2022
@ghost ghost requested review from kairu-ms and necusjz August 30, 2022 18:45
@ghost ghost assigned kairu-ms Aug 30, 2022
@ghost ghost added this to the Aug 2022 (2022-09-06) milestone Aug 30, 2022
@ghost ghost requested a review from yonzhan August 30, 2022 18:45
@ghost ghost added the Quantum az quantum label Aug 30, 2022
@ghost ghost requested a review from wangzelin007 August 30, 2022 18:45
@yonzhan
Copy link
Collaborator

yonzhan commented Aug 31, 2022

Quantum

@wangzelin007
Copy link
Member

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@yonzhan yonzhan added this to the Jan 2023 (2023-02-07) milestone Jan 9, 2023
@warren-jones warren-jones changed the title [Quantum] [DRAFT - Do not merge] Submit jobs directly to service [Quantum] [DRAFT - Do not merge] Submit jobs directly to service, Phase 1 Jan 24, 2023
@warren-jones warren-jones changed the title [Quantum] [DRAFT - Do not merge] Submit jobs directly to service, Phase 1 [Quantum] Submit jobs directly to service, Phase 1 Feb 1, 2023
@warren-jones warren-jones marked this pull request as ready for review February 1, 2023 01:52
@@ -34,6 +34,7 @@
]

DEPENDENCIES = [
'azure-storage-blob~=12.14.1'
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @evelyn-ys, can an extension dependence on a specific version of 'azure-storage-blob'?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we don't recommend one extension to depend on another one....

Why does quantum need to use azure-storage-blob?

Copy link
Contributor Author

@warren-jones warren-jones Feb 3, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It is not depending on another extension. It is depending on a published PyPi package, azure-storage-blob from the Azure SDK for Python.

Why?
To submit a job to quantum hardware or a simulator, the client of the quantum service must upload a quantum program to a blob in an Azure storage account. In the past, there was only one method of submitting a quantum job with the CLI: Create a Q# program and use the Q# compiler. The compiler builds a .NET executable that performs the upload. To generalize CLI job-submission to support many other quantum programming languages in addition to Q#, the quantum CLI extension needs to perform this blob upload.

The Quantum QDK provides an SDK called qdk-python that aids in managing Azure Quantum programming with a Python client. The blob-upload code being added to the CLI extension in this PR is based on code in qdk-python. The qdk-python code depends on the azure-storage-blob PyPi package.

Copy link
Contributor Author

@warren-jones warren-jones Feb 3, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Other extensions have dependencies on various PyPi packages, for example:

src\cloudservice\setup.py

DEPENDENCIES = [
    'azure-mgmt-compute~=20.0.0'
]

src\connectedk8s\setup.py

DEPENDENCIES = [
    'kubernetes==24.2.0',
    'pycryptodome==3.14.1',
    'azure-mgmt-hybridcompute==7.0.0'
]

src\db-up\setup.py

DEPENDENCIES = [
    'Cython==0.29.17',
    'mysql-connector-python==8.0.14',
    'psycopg2-binary==2.9.1'
]

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It seems azure-storage-blob is not used in azure-cli repo. Approved.

@kairu-ms kairu-ms merged commit c9bf404 into Azure:main Feb 6, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Auto-Assign Auto assign by bot Quantum az quantum
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants