-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
plot_bloch_vector (and others) no longer directly importable from qiskit.tools.visualization #847
Comments
Nice catch @dtmcclure ! I'm actually unsure about the best solution: perhaps the best way is to update the The reason would be that |
We want the plot_bloch_vector as a function. |
This was done to give users one unified interface for plotting density matrices:
where So I would also vote for keeping that the "public" interface, and the underlying methods as private. |
yeah, I agree but the point is you can plot a Bloch sphere with much less information than a state as it is not informationally complete. I am fine with the others not being accessed unless using state but this one I think should be special. I can't believe i'm defending the Bloch sphere when I think this is the worst thing physicists ever got used to helping explain quantum computing. The plot_state method should only use rho but the plot_vector uses the smaller vector format. The reason is also when using it for education i dont want to make a rho when we dont need to. |
Thanks for the clarification. I made a PR to make the |
@ajavadia we can close this correct? |
Informations
What is the current behavior?
The command from qiskit.tools.visualization import plot_bloch_vector no longer works now that this function is defined in the file _state_visualization.py in the visualization folder, rather than in the file visualization.py. Perhaps this is intentional, but in that case then the file qiskit/python/quantum_phase_bloch.py in the repository ibmqx-user-guides should be updated accordingly.
Steps to reproduce the problem
What is the expected behavior?
Suggested solutions
The text was updated successfully, but these errors were encountered: