Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replaced numpy.asfarray with numpy.asarray using the proper dtype. #169

Merged
merged 3 commits into from
Sep 6, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
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
Prev Previous commit
Next Next commit
Newer version of numpy return np.True_ instead of True. Changed this …
…in two doctests.
  • Loading branch information
skrylow authored and skrylow committed Sep 2, 2024
commit 32edd81510a0bcee3a831ca42028bc65d29696c3
2 changes: 1 addition & 1 deletion KDEpy/BaseKDE.py
Original file line number Diff line number Diff line change
Expand Up @@ -191,7 +191,7 @@ def _process_sequence(sequence_array_like):
--------
>>> res = BaseKDE._process_sequence([1, 2, 3])
>>> (res == np.array([[1], [2], [3]])).all()
True
np.True_
"""
# Must convert to float to avoid possible interger overflow
if isinstance(sequence_array_like, Sequence):
Expand Down
2 changes: 1 addition & 1 deletion KDEpy/kernel_funcs.py
Original file line number Diff line number Diff line change
Expand Up @@ -253,7 +253,7 @@ def __init__(self, function, var=1, support=3):
>>> kernel = Kernel(exp, var=4, support=np.inf)
>>> # The function is scaled so that the standard deviation (bw) = 1
>>> kernel(0, bw=1, norm=2)[0] > kernel(1, bw=1, norm=2)[0]
True
np.True_
>>> np.allclose(kernel(np.array([0, 1, 2])), kernel([0, 1, 2]))
True
>>> np.allclose(kernel(0), kernel([0]))
Expand Down
Loading