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

Added |2> -> |1> amplitude damping to amplitude damping. #5757

Merged
merged 18 commits into from
Jun 3, 2024

Conversation

Gabriel-Bottrill
Copy link
Contributor

@Gabriel-Bottrill Gabriel-Bottrill commented May 29, 2024

Context:
I recently added qml.QutritAmplitudeDamping based on specifications from this paper. This paper only considers the transition from |2> to |0>, in reality on a super conducting device it is more likely to have a |2> to |1> transition. This PR adds a variable and a new Kraus matrix to qml.QutritAmplitudeDamping to allow for the simulation of the |2> to |1> transition.

Description of the Change:
Adds a new variable, \gamma_3, to qml.QutritAmplitudeDamping that defines the new Kraus matrix K_3. This new Kraus operator allows for the simulation of |2> to |1> relaxations.

Benefits:
Allows for simulation of |2> to |1> relaxation. This will make for more accurate simulations and is useful for measurement error for qutrits.

Possible Drawbacks:
This changes qml.QutritAmplitudeDamping and adds an extra parameter, the naming may be a bit more confusing.

Related GitHub Issues:
N/A

Copy link
Contributor

@trbromley trbromley left a comment

Choose a reason for hiding this comment

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

Nice, thanks @Gabriel-Bottrill!

@trbromley trbromley requested a review from mudit2812 May 29, 2024 14:15
Copy link
Contributor

@mudit2812 mudit2812 left a comment

Choose a reason for hiding this comment

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

Just spotted that default.qutrit.mixed is missing from the docs for pennylane/__init__.py:device() (see here). Can you add that in this PR?

@Gabriel-Bottrill
Copy link
Contributor Author

@mudit2812 I added this.

Copy link

codecov bot commented May 29, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 99.66%. Comparing base (c83d98c) to head (770ca93).
Report is 257 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #5757      +/-   ##
==========================================
- Coverage   99.67%   99.66%   -0.01%     
==========================================
  Files         414      414              
  Lines       39310    39021     -289     
==========================================
- Hits        39181    38891     -290     
- Misses        129      130       +1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@Gabriel-Bottrill
Copy link
Contributor Author

Hi @albi3ro, @glassnotes, @mudit2812, @trbromley; I didn't tag you all earlier as I didn't intend to make this a full PR, I missclicked when trying to make it a draft. I fixed the issues and it is finalized now, ready for review.

Copy link
Contributor

@glassnotes glassnotes left a comment

Choose a reason for hiding this comment

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

Good catch @Gabriel-Bottrill , thanks for improving this channel implementation!

pennylane/ops/qutrit/channel.py Outdated Show resolved Hide resolved
Gabriel-Bottrill and others added 2 commits June 3, 2024 13:08
Co-authored-by: Olivia Di Matteo <2068515+glassnotes@users.noreply.github.com>
@mudit2812 mudit2812 enabled auto-merge (squash) June 3, 2024 20:18
@mudit2812 mudit2812 merged commit 456e474 into PennyLaneAI:master Jun 3, 2024
40 checks passed
glassnotes added a commit that referenced this pull request Jun 6, 2024
**Context:**
The QutritAmplitudeDamping channel #5503 and #5757 variable names are
named with numbers, when making the TritFlip channel #5784 I realized
that it would be better to specify subspaces for clarity. This PR is
meant to change the name of QutritAmplitudeDamping's variables.

**Description of the Change:**
Change the name of the QutritAmplitudeDamping channel's variables from
gamma_1, gamma_2, and gamma_3 to gamma_01, gamma_02, and gamma_12,
respectively.

**Benefits:**
Makes the code more clear for which variables affect which subspace,
reducing the need to check the docs.

**Possible Drawbacks:**
Changes the name of variables of development code.

**Related GitHub Issues:**
N/A

---------

Co-authored-by: Gabriel Bottrill <bottrill@student.ubc.ca>
Co-authored-by: Olivia Di Matteo <2068515+glassnotes@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants