File tree Expand file tree Collapse file tree 1 file changed +6
-3
lines changed Expand file tree Collapse file tree 1 file changed +6
-3
lines changed Original file line number Diff line number Diff line change 31
31
32
32
33
33
def set_boundary (Xs : TensorLike , c : numbers .Real | TensorLike ) -> np .ndarray :
34
- """Set the boundary using the `Xs` centered around 0 and `c`. `c` is usually a scalar
35
- multiplier greater than 1.0, but it may be one value per dimension or column of `Xs`.
34
+ """Set the boundary using the `Xs` and `c`. `Xs` must be centered around zero, and `c`
35
+ is usually a scalar multiplier greater than 1.0, but it may also be one value per dimension
36
+ or column of `Xs`.
36
37
"""
37
- S = pt .max (pt .abs (Xs ), axis = 0 ) # important: the Xs should be centered around 0
38
+ S = pt .max (
39
+ pt .abs (Xs ), axis = 0
40
+ ) # important: the Xs should have previously been centered around 0
38
41
L = (c * S ).eval () # eval() makes sure L is not changed with out-of-sample preds
39
42
return L
40
43
You can’t perform that action at this time.
0 commit comments