Fix docstring hiding due to #45689 (#73747)
Summary:
Fixes hiding of the `CatTransform` docstring due to a misplaced type annotation in https://github.com/pytorch/pytorch/issues/45689.
Also fixes that annotation and adds to to `StackTransform` to keep `CatTransform` similar.
Pull Request resolved: https://github.com/pytorch/pytorch/pull/73747
Reviewed By: mruberry
Differential Revision: D34649927
Pulled By: neerajprad
fbshipit-source-id: e4594fd76020a37ac4cada88e5fb08191984e911
(cherry picked from commit cec256c3242d1cf55073a980060af87c1fd59ac9)