Revert "Move functional collectives implementation to python. (#98315)"
This reverts commit 8b0374f83c605c47b7c1ba9274011c4b961666ce.
Reverted https://github.com/pytorch/pytorch/pull/98315 on behalf of https://github.com/huydhn due to Sorry for reverting for PR. This is failing in trunk probably due to a landrace