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

Prepare the qutip-qip-0.2.3 release #175

Merged
merged 16 commits into from
Dec 12, 2022

Conversation

BoxiLi
Copy link
Member

@BoxiLi BoxiLi commented Oct 23, 2022

No description provided.

BoxiLi and others added 10 commits October 23, 2022 17:37
* add version test for definition of rand_unitary

* fix usage of rand_ket and rand_unitary
Fix the final time calculation in `_concatenate_pulses`.
* Fix bug for circuit with selected measurement result

The parameter measure_results was not correctly processed in QubitCircuit.run because the Simulator is initialized twice. This commit removes the parameters `state`, `cbits` and `measure_results` from the `__init__` of CircuitSimulator and only initializes the simulator before it is run.

The CircuitSimulator class should only include information about the circuit while the information about the state is only provided when running the simulation.
* Fix bugs in the analytical pulse shapes

- Fix bugs in the analytical pulse shapes
- Compress the test. The test no longer depends on the processor class. Test both the maximum and the total area.
- Add a minus sign for plotting the swap gate

- Add a border so that SWAP gates are not cropped.

- Remove the unnecessary redefinition of qswap
qutip 5 uses more recently syntax and no longer support Python 3.6.
BoxiLi and others added 5 commits December 11, 2022 22:05
SWAP needs to be treated differently for circuits with reversed and non-reversed states order.
Co-Authored-By: Simon Cross <165551+hodgestar@users.noreply.github.com>
Use the atol option in qutip to determine the tolerance for measurement. And filter out the states with a probability smaller than this.
Add a default max_step based on the total circuit time.

This does not solve the problem completely. But it will avoid those mistakes that keep popping up when people try and compile one gate and send it to the solver. When there are more gates and a non-trivial circuit, the probability of this happening will be very low.
@hodgestar
Copy link
Contributor

It's always hard to review these, but it looks good to me.

@BoxiLi BoxiLi merged commit 3db2c7a into qutip:qutip-qip-0.2.X Dec 12, 2022
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.

None yet

3 participants