Skip to content

Commit b804512

Browse files
committed
Fixed #1119 Pandas to NumPy array read-only error
1 parent cc6546b commit b804512

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

stumpy/core.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2133,6 +2133,9 @@ def _preprocess(T, copy=True):
21332133

21342134
T = transpose_dataframe(T)
21352135

2136+
if "pandas" in str(type(T)):
2137+
T = T.to_numpy(copy=True)
2138+
21362139
if "polars" in str(type(T)):
21372140
T = T.to_numpy(writable=True)
21382141

0 commit comments

Comments
 (0)