Skip to content

feat(circuits): add Circuit.to_pytket() export#23

Open
crnlchez1234-afk wants to merge 1 commit into
marqov-dev:mainfrom
crnlchez1234-afk:feature/circuit-to-pytket
Open

feat(circuits): add Circuit.to_pytket() export#23
crnlchez1234-afk wants to merge 1 commit into
marqov-dev:mainfrom
crnlchez1234-afk:feature/circuit-to-pytket

Conversation

@crnlchez1234-afk

Copy link
Copy Markdown

Implements unitaryHACK26 bounty #3:

  • Add to_pytket() method using Qiskit bridge (Marqov -> Qiskit -> pytket)
  • Add test_bell_state_roundtrip() for faithfulness test
  • Add test_handwritten_bell_state() for hand-written circuit comparison
  • Add test_import_error_without_pytket() for error handling
  • Add test_rotation_gates_preserve_angles() for parameterized gates
  • Documentation in circuits.py alongside other to_* methods

Closes #3

Summary

Brief description of what this PR does.

Type of change

  • Bug fix
  • New executor
  • Circuit format converter
  • Documentation
  • Other (describe):

Testing

  • I ran pytest tests/ -v and tests pass
  • For new executors: tested against local simulator or QVM (describe below)
  • For circuit converters: roundtrip test passes with known-correct reference circuit

Test details:

Checklist

  • No hardcoded credentials or API keys
  • Handles the canonical gate set from CONTRIBUTING.md §1 (if adding a circuit converter)

For new executors only:

  • Registered in ExecutorFactory per CONTRIBUTING.md §3
  • get_status() returns device-level availability ("online"/"offline"/"maintenance"), not job-level status

Implements unitaryHACK26 bounty marqov-dev#3:
- Add to_pytket() method using Qiskit bridge (Marqov -> Qiskit -> pytket)
- Add test_bell_state_roundtrip() for faithfulness test
- Add test_handwritten_bell_state() for hand-written circuit comparison
- Add test_import_error_without_pytket() for error handling
- Add test_rotation_gates_preserve_angles() for parameterized gates
- Documentation in circuits.py alongside other to_* methods

Closes marqov-dev#3
@ddri

ddri commented Jun 5, 2026

Copy link
Copy Markdown
Contributor

Thanks for the PR. Just checking first that you've registered for the uniartyHACK event, have read the two instructions at the bottom of the GitHub Issue, and are following the AI disclosure? Those are necessary to consider submissions for the bounty.

@crnlchez1234-afk

Copy link
Copy Markdown
Author

@ddri Yes, I have registered for the unitaryHACK event. I have read the two instructions at the bottom of the GitHub issue and I am following the AI disclosure guidelines as specified in the bounty requirements.

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.

feat(circuits): add Circuit.to_pytket() export

2 participants