Updated Public API definition and documentation (markdown)

albanD
2022-04-13 11:15:57 -04:00
parent 0f6a2885eb
commit f2b0a29486

@ -8,8 +8,8 @@ Other objects, in particular functions and classes, are public if they have a `_
To ensure that we can check that all objects that "looks public" are expected, we also have the following constraints for public submodules within the torch namespace. They should either:
- Define `__all__`
- In this case, all callable and classes in `__all__` must have their `__module__` start with the current submodules path.
- All attributes that are not in `__all__` must NOT have their `__module__` start with the current submodule's path.
- In this case, all callable and classes in `__all__` must have their `__module__` start with the current submodule.
- All attributes that are not in `__all__` must NOT have their `__module__` start with the current submodule.
- Not define `__all__`
- In this case, all the objects in `dir(submod)` must have their `__module__` that start with the current submodule.