qiskit-community / qiskit-nature

Qiskit Nature is an open-source, quantum computing, framework for solving quantum mechanical natural science problems.
https://qiskit-community.github.io/qiskit-nature/
Apache License 2.0
306 stars 207 forks source link

Tutorial 12_deuteron_binding_energy needs updating #1295

Closed woodsp-ibm closed 9 months ago

woodsp-ibm commented 12 months ago

The tutorial is emitting some deprecation warnings and headings need fixing for the new style. I will note the algorithm globals seed comes as a result qiskit_algorithms compatibility with the former globals usage as it delegates to that if it exists. This will go away (already been deleted in main) for Qiskit 1.0.0 and the messages with it! I noticed the heading level issue first, as they show up in the toc, and looking inside saw the warnings...

Deprecation Warnings

  1. In cell 21 - the method its calling should be updated to use assign parameters

/tmp/ipykernel_3808/3240817257.py:25: DeprecationWarning: The method qiskit.circuit.quantumcircuit.QuantumCircuit.bind_parameters() is deprecated as of qiskit 0.45.0. It will be removed no earlier than 3 months after the release date. Use assign_parameters() instead qc = quantum_circuit.bind_parameters({theta: angle})

  1. In cell 7 and 8 the draw style should be updated

/opt/hostedtoolcache/Python/3.8.18/x64/lib/python3.8/site-packages/qiskit/visualization/circuit/matplotlib.py:266: FutureWarning: The default matplotlib drawer scheme will be changed to "iqp" in a following release. To silence this warning, specify the current default explicitly as style="clifford", or the new default as style="iqp". self._style, def_font_ratio = load_style(self._style)

I will note that the same style warning shows up in this tutorial too tutorials/11_quadratic_hamiltonian_and_slater_determinants Maybe that can be fixed at the same time.

Heading styles

The headings need adjusting so they do not show up in left toc as can be see here - it should just be the list of tutorials

image