MilesCranmer commited on
Commit
2312011
1 Parent(s): 9738395

Update docstring of `full_objective`

Browse files
Files changed (1) hide show
  1. pysr/sr.py +1 -1
pysr/sr.py CHANGED
@@ -345,7 +345,7 @@ class PySRRegressor(MultiOutputMixin, RegressorMixin, BaseEstimator):
345
  function eval_loss(tree, dataset::Dataset{T,L}, options)::L where {T,L}
346
  prediction, flag = eval_tree_array(tree, dataset.X, options)
347
  if !flag
348
- return T(Inf)
349
  end
350
  return sum((prediction .- dataset.y) .^ 2) / dataset.n
351
  end
 
345
  function eval_loss(tree, dataset::Dataset{T,L}, options)::L where {T,L}
346
  prediction, flag = eval_tree_array(tree, dataset.X, options)
347
  if !flag
348
+ return L(Inf)
349
  end
350
  return sum((prediction .- dataset.y) .^ 2) / dataset.n
351
  end