File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -572,7 +572,7 @@ def lpu_p(
572572 in general tensor form (for parameter uncertainty tensors).
573573
574574 Using Einstein's summation convention and the symmetry of the
575- input uncertainty tensor :math:`U`:, the output uncertainty
575+ parameter uncertainty tensor :math:`U`:, the output uncertainty
576576 tensor reads:
577577
578578 .. math::
@@ -645,7 +645,7 @@ def lpu_x(
645645def make_lpu (
646646 d : int , diag : bool = False
647647) -> Callable [[np .ndarray , np .ndarray ], np .ndarray ]:
648- r """
648+ """
649649 Returns the law of propagation of uncertainty.
650650
651651 :param d: The number of inner tensor dimensions.
@@ -654,6 +654,7 @@ def make_lpu(
654654 """
655655
656656 def lpu (g : np .ndarray , u : np .ndarray ) -> np .ndarray :
657+ """The law of propagation of uncertainty."""
657658 dims = tuple (range (- d , 0 ))
658659 gu = np .tensordot (g , u , (dims , dims )) if u .ndim != d else g * u
659660 return (
You can’t perform that action at this time.
0 commit comments