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

Add circuit to_cirq and from_cirq functionality #68

Open
refraction-ray opened this issue Oct 27, 2022 · 3 comments
Open

Add circuit to_cirq and from_cirq functionality #68

refraction-ray opened this issue Oct 27, 2022 · 3 comments
Labels
good first issue Good for newcomers

Comments

@refraction-ray
Copy link
Contributor

refraction-ray commented Oct 27, 2022

Task description

Similar to AbstractCircuit.to_qiskit method, ultimately we would like to transform tensorcircuit Circuit with cirq Circuit as well.

Implementation

Add functions similar to qir2qiskit in https://github.com/tencent-quantum-lab/tensorcircuit/blob/master/tensorcircuit/translation.py. And then add a wrapper method in https://github.com/tencent-quantum-lab/tensorcircuit/blob/master/tensorcircuit/abstractcircuit.py as .to_cirq and .from_cirq.
Add test similar to https://github.com/tencent-quantum-lab/tensorcircuit/blob/master/tests/test_circuit.py#L845 accordingly.

Requirements

Difficulty: ★★★

@refraction-ray refraction-ray added the good first issue Good for newcomers label Oct 27, 2022
@JettChenT
Copy link

JettChenT commented Jul 10, 2023

Hi! I'm willing to work on this issue.
After a look in the code base, the to_cirq and qir2cirq functionalities are already implemented in #106 .

I suppose I can work on from_cirq? Thanks!

@refraction-ray
Copy link
Contributor Author

@JettChenT , thanks for your interest, feel free to contribute and open pr on this issue!

For to_cirq, the implementation now is not complete in terms of different gates, at least we need an equivalent translation of commonly used rxx, ryy, rzz gates which is lacking now.
And we now have no function for from_cirq which is also welcome to contribute.

@JettChenT
Copy link

Got it, thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

2 participants