Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion docs/sphinx/source/whatsnew/v0.13.2.rst
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ Deprecations
Bug fixes
~~~~~~~~~


Enhancements
~~~~~~~~~~~~
* Add :py:func:`~pvlib.ivtools.sdm.fit_desoto_batzelis`, a function to estimate
Expand Down Expand Up @@ -56,6 +55,8 @@ Testing
* Add Python 3.14 to test suite. (:pull:`2590`)
* Update pytest configuration in ``pyproject.toml`` to work with pytest 9.0.
(:pull:`2596`)
* Correct argument and value order in :py:func:`~pvlib.tests.ivtools.test_sde`,
in tests of :py:func:`~pvlib.ivtools.sde._fit_sandia_cocontent`. (:issue:`2613`, :pull:`2615`)


Benchmarking
Expand Down
6 changes: 3 additions & 3 deletions tests/ivtools/test_sde.py
Original file line number Diff line number Diff line change
Expand Up @@ -57,18 +57,18 @@ def test_fit_sandia_simple_bad_iv(get_bad_iv_curves):
(np.array([3., 2.9, 2.8, 2.7, 2.6, 2.5, 2.4, 1.7, 0.8, 0.]),
np.array([0., 0.2, 0.4, 0.6, 0.8, 1., 1.2, 1.4, 1.45, 1.5]),
10.,
(2.3392, 11.6865, -.232, -.2596, -.7119)),
(2.3392, 11.6865, -.2596, -.232, -.7119)),
(np.array(
[5., 4.9, 4.8, 4.7, 4.6, 4.5, 4.4, 4.3, 4.2, 4.1, 4., 3.8, 3.5, 1.7,
0.]),
np.array(
[0., .1, .2, .3, .4, .5, .6, .7, .8, .9, 1., 1.1, 1.18, 1.2, 1.22]),
15.,
(-22.0795, 27.1196, -4.2076, -.0056, -.0498))])
(-22.0795, 27.1196, -.0056, -4.2076, -.0498))])
def test__fit_sandia_cocontent(i, v, nsvth, expected):
# test confirms agreement with Matlab code. The returned parameters
# are nonsense
iph, io, rsh, rs, n = sde._fit_sandia_cocontent(v, i, nsvth)
iph, io, rs, rsh, n = sde._fit_sandia_cocontent(v, i, nsvth)
np.testing.assert_allclose(iph, np.array(expected[0]), atol=.0001)
np.testing.assert_allclose(io, np.array([expected[1]]), atol=.0001)
np.testing.assert_allclose(rs, np.array([expected[2]]), atol=.0001)
Expand Down