Skip to content

Commit

Permalink
Implement Kikuchi guiding state preparation (#1504)
Browse files Browse the repository at this point in the history
* Add list primitives from Quartic speedups paper

* notebook

* fix tests

* Implement Kikuchi guiding state preparation

* rename folder

* rename `kikuchi_guiding_state.py`

* add notebook spec

---------

Co-authored-by: Tanuj Khattar <tanujkhattar@google.com>
  • Loading branch information
anurudhp and tanujkhattar authored Jan 22, 2025
1 parent 5aee458 commit 5a1b03a
Show file tree
Hide file tree
Showing 9 changed files with 1,510 additions and 0 deletions.
16 changes: 16 additions & 0 deletions dev_tools/qualtran_dev_tools/notebook_specs.py
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,7 @@
import qualtran.bloqs.multiplexers.black_box_select
import qualtran.bloqs.multiplexers.select_base
import qualtran.bloqs.multiplexers.select_pauli_lcu
import qualtran.bloqs.optimization.k_xor_sat.kikuchi_guiding_state
import qualtran.bloqs.phase_estimation.lp_resource_state
import qualtran.bloqs.phase_estimation.qubitization_qpe
import qualtran.bloqs.phase_estimation.text_book_qpe
Expand Down Expand Up @@ -796,6 +797,20 @@
),
]

# --------------------------------------------------------------------------
# ----- Optimization ---------------------------------------------------
# --------------------------------------------------------------------------
OPTIMIZATION: List[NotebookSpecV2] = [
NotebookSpecV2(
title='Planted Noisy kXOR - Kikuchi Guiding State',
module=qualtran.bloqs.optimization.k_xor_sat.kikuchi_guiding_state,
bloq_specs=[
qualtran.bloqs.optimization.k_xor_sat.kikuchi_guiding_state._SIMPLE_GUIDING_STATE_DOC,
qualtran.bloqs.optimization.k_xor_sat.kikuchi_guiding_state._GUIDING_STATE_DOC,
],
)
]

# --------------------------------------------------------------------------
# ----- Other ----------------------------------------------------------
# --------------------------------------------------------------------------
Expand Down Expand Up @@ -912,5 +927,6 @@
('GF Arithmetic', GF_ARITHMETIC),
('Rotations', ROT_QFT_PE),
('Block Encoding', BLOCK_ENCODING),
('Optimization', OPTIMIZATION),
('Other', OTHER),
]
6 changes: 6 additions & 0 deletions docs/bloqs/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -137,6 +137,12 @@ Bloqs Library
block_encoding/chebyshev_polynomial.ipynb
block_encoding/lcu_block_encoding.ipynb

.. toctree::
:maxdepth: 2
:caption: Optimization:

optimization/k_xor_sat/kikuchi_guiding_state.ipynb

.. toctree::
:maxdepth: 2
:caption: Other:
Expand Down
15 changes: 15 additions & 0 deletions qualtran/bloqs/optimization/k_xor_sat/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# Copyright 2024 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
from .kikuchi_guiding_state import GuidingState, SimpleGuidingState
from .kxor_instance import Constraint, KXorInstance
Loading

0 comments on commit 5a1b03a

Please sign in to comment.