Skip to content

Commit

Permalink
updating test tolerance
Browse files Browse the repository at this point in the history
  • Loading branch information
karllark committed Nov 15, 2024
1 parent f4cc6cd commit 0475996
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
5 changes: 3 additions & 2 deletions dust_extinction/shapes.py
Original file line number Diff line number Diff line change
Expand Up @@ -121,8 +121,9 @@ def _curve_F99_method(

spline_x = np.concatenate([x_splineval_optir, x_splineval_uv])
spline_y = np.concatenate([y_splineval_optir, y_splineval_uv])
spline_rep = interpolate.splrep(spline_x, spline_y)
axav[indxs_opir] = interpolate.splev(x[indxs_opir], spline_rep, der=0)
axav[indxs_opir] = interpolate.CubicSpline(spline_x, spline_y, bc_type='natural')(x[indxs_opir])
#spline_rep = interpolate.splrep(spline_x, spline_y)
#axav[indxs_opir] = interpolate.splev(x[indxs_opir], spline_rep, der=0)

# return A(x)/A(V)
return axav
Expand Down
2 changes: 1 addition & 1 deletion dust_extinction/tests/test_corvals.py
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@
"Rv": 3.1,
"x_values": [0.377, 0.820, 1.667, 1.828, 2.141, 2.433, 3.704, 3.846],
"y_values": np.array([0.185, 0.772, 2.688, 3.055, 3.805, 4.315, 6.456, 6.781]) / 3.1,
"atol": 1e-3,
"atol": 4e-3,
# from Fitzpatrick (1999) Table 3
# keep optical from Fitzpatrick (1999),
# replce NIR with Fitzpatrick (2004) function for Rv=3.1:
Expand Down

0 comments on commit 0475996

Please sign in to comment.