Skip to content

DOC: clarify nan_to_num copy= semantics - #32337

Closed
arcabotai wants to merge 1 commit into
numpy:mainfrom
arcabotai:cursor/doc-nan-to-num-copy-ce8d
Closed

arcabotai wants to merge 1 commit into
numpy:mainfrom
arcabotai:cursor/doc-nan-to-num-copy-ce8d

Conversation

@arcabotai

Copy link
Copy Markdown

Summary

Docs-only fix for #29045.

nan_to_num(..., copy=) is passed through to np.array, so True always copies, False never copies (ValueError if a copy is required), and None copies only if needed. The current docstring still describes 1.x semantics.

Test plan

  • Docs render; no code change.

The copy parameter is passed through to np.array, so True always
copies, False never copies (ValueError if a copy is required), and
None copies only if needed. See numpy#29045.

Co-authored-by: Arca <[email protected]>
@jorenham

Copy link
Copy Markdown
Member

You ignored the PR template, so I'm going to assume that this PR has been made with agentic AI. This violates our AI policy; we prefer to talk to humans.

@jorenham jorenham closed this Aug 18, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants