There are some classes written with the docstring at the class level, as opposed to under methods like the init method, for example PyTorch's CrossEntropy loss class.
How can I show the class docstring in VSCode with a shortcut, similar to this question?
"editor.hover.enabled": true
in yoursettings.json
file, you should see the class docstring when hovering over an instance of that class with your mouse, but I'm not sure of a keyboard shortcut for this offhand. That said, methods that are members of that class will show their own docstrings on hover, not their parent class's.