torch.nn.utils.parametrize.register_parametrization
torch.nn.utils.parametrize.register_parametrization(module, tensor_name, parametrization, *, unsafe=False)
Adds a parametrization to a tensor in a module.
Assume that "tensor_name="weight"" for simplicity. When accessing
   "module.weight", the module will return the parametrized version
   "parametrization(module.weight)". If the original tensor requires a
   gradient, the backward pass will differentiate through
   "parametrization", and the optimizer will update the tensor
   accordingly.
The first time that a module registers a parametrization, this
   function will add an attribute "parametrizations" to the module of
   type "ParametrizationList".
The list of parametrizations on the tensor "weight" will be
   accessible under "module.parametrizations.weight".
The original tensor will be accessible under
   "module.parametrizations.weight.original".