Skip to content

Commit

Permalink
Add context-dependent bounds for scales
Browse files Browse the repository at this point in the history
  • Loading branch information
kboone committed Sep 17, 2019
1 parent de38095 commit f89a77d
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion avocado/astronomical_object.py
Original file line number Diff line number Diff line change
Expand Up @@ -213,7 +213,10 @@ def grad_neg_ln_like(p):

bounds = [(0, np.log(1000**2))]
if not fix_scale:
bounds = [(-30, 30)] + bounds
bounds = (
[(guess_parameters[0] - 10, guess_parameters[0] + 10)]
+ bounds
)

fit_result = minimize(
neg_ln_like,
Expand Down

0 comments on commit f89a77d

Please sign in to comment.