amazon-braket-sdk-python icon indicating copy to clipboard operation
amazon-braket-sdk-python copied to clipboard

feature: Introduce Validating Emulators with Noise Models to the SDK

Open Altanali opened this issue 1 year ago • 2 comments

Issue #, if available:

Description of changes:

This PR introduces the notion of device emulators and emulation passes to the BDK; device emulators provide some form of program compilation and validation and may apply a noise model to the program before simulating the program on the BDK LocalSimulator.

AwsDevice specific emulators are created based on the device properties and capabilities; noise models for gate-based QPUs are created based on calibration data retrieved from Braket service when creating an AwsDevice.

Testing done:

Unit testing covers 99% of emulator passes and noise model generation based on AwsDevice calibration data. (TODO: Complete unit tests for 100% coverage).

Merge Checklist

Put an x in the boxes that apply. You can also fill these out after creating the PR. If you're unsure about any of them, don't hesitate to ask. We're here to help! This is simply a reminder of what we are going to look for before merging your pull request.

General

Tests

  • [x] I have added tests that prove my fix is effective or that my feature works (if appropriate)
  • [x] I have checked that my tests are not configured for a specific region or account (if appropriate)

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

Altanali avatar Jul 10 '24 23:07 Altanali

Codecov Report

:white_check_mark: All modified and coverable lines are covered by tests. :white_check_mark: Project coverage is 100.00%. Comparing base (789588f) to head (b8d2531). :warning: Report is 71 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##              main     #1017    +/-   ##
==========================================
  Coverage   100.00%   100.00%            
==========================================
  Files          146       162    +16     
  Lines         9879     10387   +508     
  Branches      1164      1262    +98     
==========================================
+ Hits          9879     10387   +508     

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

:rocket: New features to boost your workflow:
  • :snowflake: Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

codecov[bot] avatar Jul 15 '24 22:07 codecov[bot]

Looking good to me, let's see if @krneta has any feedback!

speller26 avatar Aug 02 '24 00:08 speller26