qiskit-optimization
qiskit-optimization copied to clipboard
Documentation of qiskit.optimization.INFINITY looks strange
What is the expected enhancement?
INFINITY is a constant to represent the infinite number.
The current description seems to be strange.
Convert a string or number to a floating point number, if possible.
https://qiskit.org/documentation/stubs/qiskit.optimization.INFINITY.html#infinity
Yes, I saw that. I tried with some constants in the operator code to do better. In the end I just listed the constants with a description rather than linking to the entity. For a simple entity like this I was going to change it to be similar, since it does not need to be so prominent
@woodsp-ibm seems like Sphinx does not parse docstrings and #: style comments for the variables at the module level. I tried to add a constant at the class level and properly commented it and everything is fine in the generated documentation. Also my IDE provides me with the same docstring for the float function. So, I think Sphinx actually takes it from the standard documentation for an unknown reason.
@adekusar-drl I had a thought on changing this that I shared earlier. To me in come out in the present docs much too prominently for my taste. I had not given this the highest priority to look at but had expected to do something ahead of the next release.
That link is dead, I suppose this issue could be closed?
The docs were moved and it looks like redirect that was in place has been discontinued. It can be seen here now
https://qiskit.org/ecosystem/optimization/apidocs/qiskit_optimization.html