Skip to content

Deprecate qiskit/transpiler/synthesis and move to qiskit/synthesis (backport #11426) #11624

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

Merged
merged 7 commits into from
Jan 24, 2024

Conversation

mergify[bot]
Copy link
Contributor

@mergify mergify bot commented Jan 23, 2024

This is an automatic backport of pull request #11426 done by Mergify.
Cherry-pick of 937ca5b has failed:

On branch mergify/bp/stable/0.46/pr-11426
Your branch is up to date with 'origin/stable/0.46'.

You are currently cherry-picking commit 937ca5b31.
  (fix conflicts and run "git cherry-pick --continue")
  (use "git cherry-pick --skip" to skip this patch)
  (use "git cherry-pick --abort" to cancel the cherry-pick operation)

Changes to be committed:
	modified:   docs/apidoc/synthesis_aqc.rst
	modified:   qiskit/circuit/library/generalized_gates/linear_function.py
	new file:   qiskit/synthesis/unitary/__init__.py
	new file:   qiskit/synthesis/unitary/aqc/__init__.py
	renamed:    qiskit/transpiler/synthesis/aqc/approximate.py -> qiskit/synthesis/unitary/aqc/approximate.py
	renamed:    qiskit/transpiler/synthesis/aqc/aqc.py -> qiskit/synthesis/unitary/aqc/aqc.py
	renamed:    qiskit/transpiler/synthesis/aqc/cnot_structures.py -> qiskit/synthesis/unitary/aqc/cnot_structures.py
	renamed:    qiskit/transpiler/synthesis/aqc/cnot_unit_circuit.py -> qiskit/synthesis/unitary/aqc/cnot_unit_circuit.py
	renamed:    qiskit/transpiler/synthesis/aqc/cnot_unit_objective.py -> qiskit/synthesis/unitary/aqc/cnot_unit_objective.py
	renamed:    qiskit/transpiler/synthesis/aqc/elementary_operations.py -> qiskit/synthesis/unitary/aqc/elementary_operations.py
	renamed:    qiskit/transpiler/synthesis/aqc/fast_gradient/__init__.py -> qiskit/synthesis/unitary/aqc/fast_gradient/__init__.py
	renamed:    qiskit/transpiler/synthesis/aqc/fast_gradient/fast_grad_utils.py -> qiskit/synthesis/unitary/aqc/fast_gradient/fast_grad_utils.py
	renamed:    qiskit/transpiler/synthesis/aqc/fast_gradient/fast_gradient.py -> qiskit/synthesis/unitary/aqc/fast_gradient/fast_gradient.py
	renamed:    qiskit/transpiler/synthesis/aqc/fast_gradient/layer.py -> qiskit/synthesis/unitary/aqc/fast_gradient/layer.py
	renamed:    qiskit/transpiler/synthesis/aqc/fast_gradient/pmatrix.py -> qiskit/synthesis/unitary/aqc/fast_gradient/pmatrix.py
	modified:   qiskit/transpiler/passes/__init__.py
	modified:   qiskit/transpiler/passes/synthesis/__init__.py
	modified:   qiskit/transpiler/synthesis/aqc/__init__.py
	deleted:    qiskit/transpiler/synthesis/aqc/aqc_plugin.py
	modified:   qiskit/transpiler/synthesis/graysynth.py
	new file:   releasenotes/notes/deprecate-transpiler-synthesis-cf4e6e6dcdb42eca.yaml
	renamed:    test/python/transpiler/aqc/__init__.py -> test/python/synthesis/aqc/__init__.py
	renamed:    test/python/transpiler/aqc/fast_gradient/__init__.py -> test/python/synthesis/aqc/fast_gradient/__init__.py
	renamed:    test/python/transpiler/aqc/fast_gradient/test_cmp_gradients.py -> test/python/synthesis/aqc/fast_gradient/test_cmp_gradients.py
	renamed:    test/python/transpiler/aqc/fast_gradient/test_layer1q.py -> test/python/synthesis/aqc/fast_gradient/test_layer1q.py
	renamed:    test/python/transpiler/aqc/fast_gradient/test_layer2q.py -> test/python/synthesis/aqc/fast_gradient/test_layer2q.py
	renamed:    test/python/transpiler/aqc/fast_gradient/test_utils.py -> test/python/synthesis/aqc/fast_gradient/test_utils.py
	renamed:    test/python/transpiler/aqc/fast_gradient/utils_for_testing.py -> test/python/synthesis/aqc/fast_gradient/utils_for_testing.py
	renamed:    test/python/transpiler/aqc/sample_data.py -> test/python/synthesis/aqc/sample_data.py
	renamed:    test/python/transpiler/aqc/test_aqc.py -> test/python/synthesis/aqc/test_aqc.py
	renamed:    test/python/transpiler/aqc/test_aqc_plugin.py -> test/python/synthesis/aqc/test_aqc_plugin.py
	renamed:    test/python/transpiler/aqc/test_cnot_networks.py -> test/python/synthesis/aqc/test_cnot_networks.py
	renamed:    test/python/transpiler/aqc/test_gradient.py -> test/python/synthesis/aqc/test_gradient.py
	modified:   test/python/synthesis/test_cnot_phase_synthesis.py

Unmerged paths:
  (use "git add <file>..." to mark resolution)
	both modified:   pyproject.toml
	both modified:   qiskit/synthesis/__init__.py
	both modified:   qiskit/transpiler/passes/synthesis/aqc_plugin.py

To fix up this pull request, you can check it out locally. See documentation: https://docs.github.com/en/github/collaborating-with-pull-requests/reviewing-changes-in-pull-requests/checking-out-pull-requests-locally


Mergify commands and options

More conditions and actions can be found in the documentation.

You can also trigger Mergify actions by commenting on this pull request:

  • @Mergifyio refresh will re-evaluate the rules
  • @Mergifyio rebase will rebase this PR on its base branch
  • @Mergifyio update will merge the base branch into this PR
  • @Mergifyio backport <destination> will backport this PR on <destination> branch

Additionally, on Mergify dashboard you can:

  • look at your merge queues
  • generate the Mergify configuration with the config editor.

Finally, you can contact us on https://mergify.com

…11426)

* deprecate transpiler/synthesis/graysynth.py

* style

* style

* move aqc_plugin to qiskit/transpiler/passes/synthesis

* remove code from qiskit/transpiler/synthesis/aqc/aqc_plugin.py

* copy qiskit/transpiler/synthesis/aqc to qiskit/synthesis/unitary

* move tests from test/python/transpiler/aqc to test/python/synthesis/aqc

* update imports in aqc_plugin

* add deprecation warning to AQC module

* handle cyclic imports

* handle cyclic imports

* update link in docs

* update init in qiskit/transpiler/synthesis/aqc

* style

* temporary remove deprecation warning test

* remove files from qiskit/transpiler/synthesis/aqc

* update link in test

* add release notes

* update docs

* update docs/apidocs/synthesis_aqc.rst

* add deprecations to qiskit/transpiler/synthesis/__init__.py

* fix link

* improve docs following review

* update docs

* add aqc to synthesis docs after review

* update qiskit/transpiler/synthesis/aqc/__init__.py after review

* update pending deprecation to deprecation in release notes

* handle cyclic imports

* update qiskit/synthesis docs following docs error

* another attempt to add AQC to synthesis docs

* another attempt to add AQC to the docs

* Revert "another attempt to add AQC to the docs"

This reverts commit 25f93ca.

* Revert "another attempt to add AQC to synthesis docs"

This reverts commit 9e87164.

* add a deprecation test for AQC

* minor

(cherry picked from commit 937ca5b)

# Conflicts:
#	pyproject.toml
#	qiskit/synthesis/__init__.py
#	qiskit/transpiler/passes/synthesis/aqc_plugin.py
@mergify mergify bot added the conflicts used by mergify when there are conflicts in a port label Jan 23, 2024
@mergify mergify bot requested a review from a team as a code owner January 23, 2024 10:03
@qiskit-bot
Copy link
Collaborator

Thank you for opening a new pull request.

Before your PR can be merged it will first need to pass continuous integration tests and be reviewed. Sometimes the review process can be slow, so please be patient.

While you're waiting, please feel free to review other open PRs. While only a subset of people are authorized to approve pull requests for merging, everyone is encouraged to review open pull requests. Doing reviews helps reduce the burden on the core team and helps make the project's code better for everyone.

One or more of the the following people are requested to review this:

@github-actions github-actions bot added the Changelog: Deprecation Include in "Deprecated" section of changelog label Jan 23, 2024
@github-actions github-actions bot added this to the 0.46.0 milestone Jan 23, 2024
@Cryoris Cryoris added Changelog: Removal Include in the Removed section of the changelog and removed conflicts used by mergify when there are conflicts in a port Changelog: Removal Include in the Removed section of the changelog labels Jan 23, 2024
@coveralls
Copy link

Pull Request Test Coverage Report for Build 7627741876

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage decreased (-0.03%) to 86.9%

Totals Coverage Status
Change from base Build 7623401427: -0.03%
Covered Lines: 74275
Relevant Lines: 85472

💛 - Coveralls

@Cryoris Cryoris enabled auto-merge January 23, 2024 17:07
@Cryoris Cryoris added this pull request to the merge queue Jan 24, 2024
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Jan 24, 2024
@ShellyGarion ShellyGarion added this pull request to the merge queue Jan 24, 2024
Merged via the queue into stable/0.46 with commit f31d134 Jan 24, 2024
@mergify mergify bot deleted the mergify/bp/stable/0.46/pr-11426 branch January 24, 2024 17:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Changelog: Deprecation Include in "Deprecated" section of changelog
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants