Skip to content

Commit 3454248

Browse files
larsonereffigies
andauthored
Apply suggestions from code review
Co-authored-by: Chris Markiewicz <[email protected]>
1 parent 4ff8ccd commit 3454248

File tree

2 files changed

+6
-7
lines changed

2 files changed

+6
-7
lines changed

nitime/timeseries.py

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -317,11 +317,10 @@ def mean(self, *args, **kwargs):
317317

318318
def ptp(self, *args, **kwargs):
319319
if _NP_2:
320-
raise AttributeError(
321-
"`ptp` was removed from the ndarray class in NumPy 2.0. "
322-
"Use np.ptp(arr, ...) instead."
323-
)
324-
ret = TimeArray(np.ndarray.ptp(self, *args, **kwargs),
320+
ptp = np.ptp
321+
else:
322+
ptp = np.ndarray.ptp
323+
ret = TimeArray(ptp(self, *args, **kwargs),
325324
time_unit=base_unit)
326325
ret.convert_unit(self.time_unit)
327326
return ret

pyproject.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -64,9 +64,9 @@ archs = ["native"]
6464

6565
test-requires = [
6666
"pytest",
67-
"pytest-cov",
67+
"nitime[full]", # Enable all optional behavior
6868
]
69-
test-command = "pytest {project}/nitime/tests"
69+
test-command = "pytest -rsx --pyargs nitime"
7070

7171
[tool.cibuildwheel.linux]
7272
archs = ["x86_64", "aarch64"]

0 commit comments

Comments
 (0)