Skip to content

Conversation

effigies
Copy link
Member

@effigies effigies commented Mar 5, 2024

Numpy 2 is changing np.array(..., copy=False) to error if the array cannot be made without copying. The semantics we want are np.asarray(...), which will not make copies if the input is already an ndarray.

cc @larsoner

Copy link

codecov bot commented Mar 5, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 92.27%. Comparing base (e4facc1) to head (2bad8cc).

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #1304   +/-   ##
=======================================
  Coverage   92.27%   92.27%           
=======================================
  Files          99       99           
  Lines       12460    12460           
  Branches     2561     2561           
=======================================
  Hits        11497    11497           
  Misses        641      641           
  Partials      322      322           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@effigies effigies merged commit d1e89ac into nipy:master Mar 5, 2024
@effigies effigies deleted the fix/array-copy branch March 5, 2024 14:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants