plenoptic-org / plenoptic

Visualize/test models for visual representation by synthesizing images.
https://plenoptic.readthedocs.io/en/latest/
MIT License
57 stars 9 forks source link

Docstring specification + type-hinting #77

Open billbrod opened 3 years ago

billbrod commented 3 years ago

Want to use type hints, what else?

Possible links:

billbrod commented 3 years ago

looks like sphinx (with numpydoc) can handle hint typing, so we don't need to have the types in two places.

billbrod commented 3 years ago

Opinioned guide to python tooling, which covers a lot of tools, some of which we already use, some of which may be useful.

billbrod commented 3 years ago

More info about docstring validation, from numpydoc

billbrod commented 3 years ago

Look into torchtyping (which allows annotation of shape and dtype)

billbrod commented 3 months ago

Because we're supporting only python 3.10 and above, can use the X|Y shorthand for Union (see docs), which will clean things up. (There's more new features as well, double-check.)