{
  "__type": "IngestedDoc",
  "__tag": 4010,
  "_content": {},
  "_ordered_sections": [],
  "item_file": null,
  "item_line": null,
  "item_type": null,
  "aliases": [],
  "example_section_data": {
    "__type": "Section",
    "__tag": 4015,
    "children": [],
    "title": [],
    "level": 0,
    "target": null
  },
  "see_also": [],
  "signature": null,
  "references": null,
  "qa": "release:2.1.0-notes",
  "arbitrary": [
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [],
      "title": [],
      "level": 0,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "NumPy 2.1.0 provides support for the upcoming Python 3.13 release and drops support for Python 3.9. In addition to the usual bug fixes and updated Python support, it helps get us back into our usual release cycle after the extended development of 2.0. The highlights for this release are:"
            }
          ]
        },
        {
          "__type": "BulletList",
          "__tag": 4053,
          "ordered": false,
          "start": 1,
          "children": [
            {
              "__type": "ListItem",
              "__tag": 4054,
              "children": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "Support for the array-api 2023.12 standard."
                    }
                  ]
                }
              ]
            },
            {
              "__type": "ListItem",
              "__tag": 4054,
              "children": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "Support for Python 3.13."
                    }
                  ]
                }
              ]
            },
            {
              "__type": "ListItem",
              "__tag": 4054,
              "children": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "Preliminary support for free threaded Python 3.13."
                    }
                  ]
                }
              ]
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "Python versions 3.10-3.13 are supported in this release."
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "Text",
          "__tag": 4046,
          "value": "NumPy 2.1.0 Release Notes"
        }
      ],
      "level": 0,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [],
      "title": [
        {
          "__type": "Text",
          "__tag": 4046,
          "value": "New functions"
        }
      ],
      "level": 1,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "A new function "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "np.unstack(array, axis=...)"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " was added, which splits an array into a tuple of arrays along an axis. It serves as the inverse of "
            },
            {
              "__type": "CrossRef",
              "__tag": 4002,
              "value": "numpy.stack",
              "reference": {
                "__type": "RefInfo",
                "__tag": 4000,
                "module": "numpy",
                "version": "*",
                "kind": "api",
                "path": "numpy:stack"
              },
              "kind": "module"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "("
            },
            {
              "__type": "Link",
              "__tag": 4049,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "gh-26579"
                }
              ],
              "url": "https://github.com/numpy/numpy/pull/26579",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ")"
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "Text",
          "__tag": 4046,
          "value": "New function "
        },
        {
          "__type": "InlineCode",
          "__tag": 4051,
          "value": "numpy.unstack"
        }
      ],
      "level": 2,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "BulletList",
          "__tag": 4053,
          "ordered": false,
          "start": 1,
          "children": [
            {
              "__type": "ListItem",
              "__tag": 4054,
              "children": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "The "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "fix_imports"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " keyword argument in "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "numpy.save"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " is deprecated. Since   NumPy 1.17, "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "numpy.save"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " uses a pickle protocol that no longer supports   Python 2, and ignored "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "fix_imports"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " keyword. This keyword is kept only   for backward compatibility. It is now deprecated."
                    }
                  ]
                },
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "("
                    },
                    {
                      "__type": "Link",
                      "__tag": 4049,
                      "children": [
                        {
                          "__type": "Text",
                          "__tag": 4046,
                          "value": "gh-26452"
                        }
                      ],
                      "url": "https://github.com/numpy/numpy/pull/26452",
                      "title": ""
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ")"
                    }
                  ]
                }
              ]
            },
            {
              "__type": "ListItem",
              "__tag": 4054,
              "children": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "Passing non-integer inputs as the first argument of "
                    },
                    {
                      "__type": "InlineRole",
                      "__tag": 4003,
                      "value": "bincount",
                      "domain": null,
                      "role": null,
                      "inventory": null
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " is now   deprecated, because such inputs are silently cast to integers with no   warning about loss of precision."
                    }
                  ]
                },
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "("
                    },
                    {
                      "__type": "Link",
                      "__tag": 4049,
                      "children": [
                        {
                          "__type": "Text",
                          "__tag": 4046,
                          "value": "gh-27076"
                        }
                      ],
                      "url": "https://github.com/numpy/numpy/pull/27076",
                      "title": ""
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ")"
                    }
                  ]
                }
              ]
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "Text",
          "__tag": 4046,
          "value": "Deprecations"
        }
      ],
      "level": 1,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "BulletList",
          "__tag": 4053,
          "ordered": false,
          "start": 1,
          "children": [
            {
              "__type": "ListItem",
              "__tag": 4054,
              "children": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "Scalars and 0D arrays are disallowed for "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "numpy.nonzero"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " and "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "numpy.ndarray.nonzero"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "."
                    }
                  ]
                },
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "("
                    },
                    {
                      "__type": "Link",
                      "__tag": 4049,
                      "children": [
                        {
                          "__type": "Text",
                          "__tag": 4046,
                          "value": "gh-26268"
                        }
                      ],
                      "url": "https://github.com/numpy/numpy/pull/26268",
                      "title": ""
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ")"
                    }
                  ]
                }
              ]
            },
            {
              "__type": "ListItem",
              "__tag": 4054,
              "children": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "set_string_function"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " internal function was removed and "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "PyArray_SetStringFunction"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "   was stubbed out."
                    }
                  ]
                },
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "("
                    },
                    {
                      "__type": "Link",
                      "__tag": 4049,
                      "children": [
                        {
                          "__type": "Text",
                          "__tag": 4046,
                          "value": "gh-26611"
                        }
                      ],
                      "url": "https://github.com/numpy/numpy/pull/26611",
                      "title": ""
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ")"
                    }
                  ]
                }
              ]
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "Text",
          "__tag": 4046,
          "value": "Expired deprecations"
        }
      ],
      "level": 1,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [],
      "title": [
        {
          "__type": "Text",
          "__tag": 4046,
          "value": "C API changes"
        }
      ],
      "level": 1,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "NumPy now defaults to hide the API symbols it adds to allow all NumPy API usage.  This means that by default you cannot dynamically fetch the NumPy API from another library (this was never possible on windows)."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "If you are experiencing linking errors related to "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "PyArray_API"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " or "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "PyArray_RUNTIME_VERSION"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ", you can define the "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "NPY_API_SYMBOL_ATTRIBUTE"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " to opt-out of this change."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "If you are experiencing problems due to an upstream header including NumPy, the solution is to make sure you "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "#include \"numpy/ndarrayobject.h\""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " before their header and import NumPy yourself based on  "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "including-the-c-api"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "("
            },
            {
              "__type": "Link",
              "__tag": 4049,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "gh-26103"
                }
              ],
              "url": "https://github.com/numpy/numpy/pull/26103",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ")"
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "Text",
          "__tag": 4046,
          "value": "API symbols now hidden but customizable"
        }
      ],
      "level": 2,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "Many of the old shims and helper functions were removed from "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "npy_3kcompat.h"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ". If you find yourself in need of these, vendor the previous version of the file into your codebase."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "("
            },
            {
              "__type": "Link",
              "__tag": 4049,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "gh-26842"
                }
              ],
              "url": "https://github.com/numpy/numpy/pull/26842",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ")"
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "Text",
          "__tag": 4046,
          "value": "Many shims removed from npy_3kcompat.h"
        }
      ],
      "level": 2,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "The field "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "process_core_dims_func"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " was added to the structure "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "PyUFuncObject"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ".  For generalized ufuncs, this field can be set to a function of type "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "PyUFunc_ProcessCoreDimsFunc"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " that will be called when the ufunc is called. It allows the ufunc author to check that core dimensions satisfy additional constraints, and to set output core dimension sizes if they have not been provided."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "("
            },
            {
              "__type": "Link",
              "__tag": 4049,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "gh-26908"
                }
              ],
              "url": "https://github.com/numpy/numpy/pull/26908",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ")"
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "Text",
          "__tag": 4046,
          "value": "New "
        },
        {
          "__type": "InlineCode",
          "__tag": 4051,
          "value": "PyUFuncObject"
        },
        {
          "__type": "Text",
          "__tag": 4046,
          "value": " field "
        },
        {
          "__type": "InlineCode",
          "__tag": 4051,
          "value": "process_core_dims_func"
        }
      ],
      "level": 2,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [],
      "title": [
        {
          "__type": "Text",
          "__tag": 4046,
          "value": "New Features"
        }
      ],
      "level": 1,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "CPython 3.13 will be available as an experimental free-threaded build. See https://py-free-threading.github.io, "
            },
            {
              "__type": "Link",
              "__tag": 4049,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "PEP 703"
                }
              ],
              "url": "https://peps.python.org/pep-0703/",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " and the "
            },
            {
              "__type": "Link",
              "__tag": 4049,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "CPython 3.13 release notes"
                }
              ],
              "url": "https://docs.python.org/3.13/whatsnew/3.13.html#free-threaded-cpython",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " for more detail about free-threaded Python."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "NumPy 2.1 has preliminary support for the free-threaded build of CPython 3.13. This support was enabled by fixing a number of C thread-safety issues in NumPy. Before NumPy 2.1, NumPy used a large number of C global static variables to store runtime caches and other state. We have either refactored to avoid the need for global state, converted the global state to thread-local state, or added locking."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "Support for free-threaded Python does not mean that NumPy is thread safe. Read-only shared access to ndarray should be safe. NumPy exposes shared mutable state and we have not added any locking to the array object itself to serialize access to shared state. Care must be taken in user code to avoid races if you would like to mutate the same array in multiple threads. It is certainly possible to crash NumPy by mutating an array simultaneously in multiple threads, for example by calling a ufunc and the "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "resize"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " method simultaneously. For now our guidance is: \"don't do that\". In the future we would like to provide stronger guarantees."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "Object arrays in particular need special care, since the GIL previously provided locking for object array access and no longer does. See "
            },
            {
              "__type": "Link",
              "__tag": 4049,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "Issue #27199"
                }
              ],
              "url": "https://github.com/numpy/numpy/issues/27199",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " for more information about object arrays in the free-threaded build."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "If you are interested in free-threaded Python, for example because you have a multiprocessing-based workflow that you are interested in running with Python threads, we encourage testing and experimentation."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "If you run into problems that you suspect are because of NumPy, please "
            },
            {
              "__type": "Link",
              "__tag": 4049,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "open an issue"
                }
              ],
              "url": "https://github.com/numpy/numpy/issues/new/choose",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ", checking first if the bug also occurs in the \"regular\" non-free-threaded CPython 3.13 build. Many threading bugs can also occur in code that releases the GIL; disabling the GIL only makes it easier to hit threading bugs."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "("
            },
            {
              "__type": "Link",
              "__tag": 4049,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "gh-26157"
                }
              ],
              "url": "https://github.com/numpy/numpy/issues/26157#issuecomment-2233864940",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ")"
            }
          ]
        },
        {
          "__type": "BulletList",
          "__tag": 4053,
          "ordered": false,
          "start": 1,
          "children": [
            {
              "__type": "ListItem",
              "__tag": 4054,
              "children": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "numpy.reshape"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " and "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "numpy.ndarray.reshape"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " now support "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "shape"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " and   "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "copy"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " arguments."
                    }
                  ]
                },
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "("
                    },
                    {
                      "__type": "Link",
                      "__tag": 4049,
                      "children": [
                        {
                          "__type": "Text",
                          "__tag": 4046,
                          "value": "gh-26292"
                        }
                      ],
                      "url": "https://github.com/numpy/numpy/pull/26292",
                      "title": ""
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ")"
                    }
                  ]
                }
              ]
            },
            {
              "__type": "ListItem",
              "__tag": 4054,
              "children": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "NumPy now supports DLPack v1, support for older versions will   be deprecated in the future."
                    }
                  ]
                },
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "("
                    },
                    {
                      "__type": "Link",
                      "__tag": 4049,
                      "children": [
                        {
                          "__type": "Text",
                          "__tag": 4046,
                          "value": "gh-26501"
                        }
                      ],
                      "url": "https://github.com/numpy/numpy/pull/26501",
                      "title": ""
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ")"
                    }
                  ]
                }
              ]
            },
            {
              "__type": "ListItem",
              "__tag": 4054,
              "children": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "numpy.asanyarray"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " now supports "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "copy"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " and "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "device"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " arguments, matching   "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "numpy.asarray"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "."
                    }
                  ]
                },
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "("
                    },
                    {
                      "__type": "Link",
                      "__tag": 4049,
                      "children": [
                        {
                          "__type": "Text",
                          "__tag": 4046,
                          "value": "gh-26580"
                        }
                      ],
                      "url": "https://github.com/numpy/numpy/pull/26580",
                      "title": ""
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ")"
                    }
                  ]
                }
              ]
            },
            {
              "__type": "ListItem",
              "__tag": 4054,
              "children": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "numpy.printoptions"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ", "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "numpy.get_printoptions"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ", and   "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "numpy.set_printoptions"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " now support a new option, "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "override_repr"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ", for   defining custom "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "repr(array)"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " behavior."
                    }
                  ]
                },
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "("
                    },
                    {
                      "__type": "Link",
                      "__tag": 4049,
                      "children": [
                        {
                          "__type": "Text",
                          "__tag": 4046,
                          "value": "gh-26611"
                        }
                      ],
                      "url": "https://github.com/numpy/numpy/pull/26611",
                      "title": ""
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ")"
                    }
                  ]
                }
              ]
            },
            {
              "__type": "ListItem",
              "__tag": 4054,
              "children": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "numpy.cumulative_sum"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " and "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "numpy.cumulative_prod"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " were added as Array   API compatible alternatives for "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "numpy.cumsum"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " and "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "numpy.cumprod"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ". The   new functions can include a fixed initial (zeros for "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "sum"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " and ones for   "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "prod"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ") in the result."
                    }
                  ]
                },
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "("
                    },
                    {
                      "__type": "Link",
                      "__tag": 4049,
                      "children": [
                        {
                          "__type": "Text",
                          "__tag": 4046,
                          "value": "gh-26724"
                        }
                      ],
                      "url": "https://github.com/numpy/numpy/pull/26724",
                      "title": ""
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ")"
                    }
                  ]
                }
              ]
            },
            {
              "__type": "ListItem",
              "__tag": 4054,
              "children": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "numpy.clip"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " now supports "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "max"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " and "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "min"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " keyword arguments which are   meant to replace "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "a_min"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " and "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "a_max"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ". Also, for "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "np.clip(a)"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " or   "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "np.clip(a, None, None)"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " a copy of the input array will be returned instead   of raising an error."
                    }
                  ]
                },
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "("
                    },
                    {
                      "__type": "Link",
                      "__tag": 4049,
                      "children": [
                        {
                          "__type": "Text",
                          "__tag": 4046,
                          "value": "gh-26724"
                        }
                      ],
                      "url": "https://github.com/numpy/numpy/pull/26724",
                      "title": ""
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ")"
                    }
                  ]
                }
              ]
            },
            {
              "__type": "ListItem",
              "__tag": 4054,
              "children": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "numpy.astype"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " now supports "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "device"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " argument."
                    }
                  ]
                },
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "("
                    },
                    {
                      "__type": "Link",
                      "__tag": 4049,
                      "children": [
                        {
                          "__type": "Text",
                          "__tag": 4046,
                          "value": "gh-26724"
                        }
                      ],
                      "url": "https://github.com/numpy/numpy/pull/26724",
                      "title": ""
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ")"
                    }
                  ]
                }
              ]
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "Text",
          "__tag": 4046,
          "value": "Preliminary Support for Free-Threaded CPython 3.13"
        }
      ],
      "level": 2,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "Pass "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "--freethreading-compatible"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " to the f2py CLI tool to produce a C extension marked as compatible with the free threading CPython interpreter. Doing so prevents the interpreter from re-enabling the GIL at runtime when it imports the C extension. Note that "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "f2py"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " does not analyze fortran code for thread safety, so you must verify that the wrapped fortran code is thread safe before marking the extension as compatible."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "("
            },
            {
              "__type": "Link",
              "__tag": 4049,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "gh-26981"
                }
              ],
              "url": "https://github.com/numpy/numpy/pull/26981",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ")"
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "InlineCode",
          "__tag": 4051,
          "value": "f2py"
        },
        {
          "__type": "Text",
          "__tag": 4046,
          "value": " can generate freethreading-compatible C extensions"
        }
      ],
      "level": 2,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [],
      "title": [
        {
          "__type": "Text",
          "__tag": 4046,
          "value": "Improvements"
        }
      ],
      "level": 1,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "For integer input data, bin sizes smaller than 1 result in spurious empty bins.  This is now avoided when the number of bins is computed using one of the algorithms provided by "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "histogram_bin_edges"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "("
            },
            {
              "__type": "Link",
              "__tag": 4049,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "gh-12150"
                }
              ],
              "url": "https://github.com/numpy/numpy/pull/12150",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ")"
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "InlineCode",
          "__tag": 4051,
          "value": "histogram"
        },
        {
          "__type": "Text",
          "__tag": 4046,
          "value": " auto-binning now returns bin sizes >=1 for integer input data"
        }
      ],
      "level": 2,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "Static typing for "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "ndarray"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " is a long-term effort that continues with this change.  It is a generic type with type parameters for the shape and the data type.  Previously, the shape type parameter could be any value.  This change restricts it to a tuple of ints, as one would expect from using "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "ndarray.shape"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ".  Further, the shape-type parameter has been changed from invariant to covariant.  This change also applies to the subtypes of "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "ndarray"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ", e.g. "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "numpy.ma.MaskedArray"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ".  See the "
            },
            {
              "__type": "Link",
              "__tag": 4049,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "typing docs"
                }
              ],
              "url": "https://typing.readthedocs.io/en/latest/reference/generics.html#variance-of-generic-types",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " for more information."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "("
            },
            {
              "__type": "Link",
              "__tag": 4049,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "gh-26081"
                }
              ],
              "url": "https://github.com/numpy/numpy/pull/26081",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ")"
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "InlineCode",
          "__tag": 4051,
          "value": "ndarray"
        },
        {
          "__type": "Text",
          "__tag": 4046,
          "value": " shape-type parameter is now covariant and bound to "
        },
        {
          "__type": "InlineCode",
          "__tag": 4051,
          "value": "tuple[int, ...]"
        }
      ],
      "level": 2,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "This changes the definition of nearest for border cases from the nearest odd order statistic to nearest even order statistic. The numpy implementation now matches other reference implementations."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "("
            },
            {
              "__type": "Link",
              "__tag": 4049,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "gh-26656"
                }
              ],
              "url": "https://github.com/numpy/numpy/pull/26656",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ")"
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "InlineCode",
          "__tag": 4051,
          "value": "np.quantile"
        },
        {
          "__type": "Text",
          "__tag": 4046,
          "value": " with method "
        },
        {
          "__type": "InlineCode",
          "__tag": 4051,
          "value": "closest_observation"
        },
        {
          "__type": "Text",
          "__tag": 4046,
          "value": " chooses nearest even order statistic"
        }
      ],
      "level": 2,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "NumPy provides a minimal low-performance version of LAPACK named "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "lapack_lite"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " that can be used if no BLAS/LAPACK system is detected at build time."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "Until now, "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "lapack_lite"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " was not thread safe. Single-threaded use cases did not hit any issues, but running linear algebra operations in multiple threads could lead to errors, incorrect results, or segfaults due to data races."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "We have added a global lock, serializing access to "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "lapack_lite"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " in multiple threads."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "("
            },
            {
              "__type": "Link",
              "__tag": 4049,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "gh-26750"
                }
              ],
              "url": "https://github.com/numpy/numpy/pull/26750",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ")"
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "InlineCode",
          "__tag": 4051,
          "value": "lapack_lite"
        },
        {
          "__type": "Text",
          "__tag": 4046,
          "value": " is now thread safe"
        }
      ],
      "level": 2,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "In prior versions of NumPy, the printoptions were defined using a combination of Python and C global variables. We have refactored so the state is stored in a python "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "ContextVar"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ", making the context manager thread and async-safe."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "("
            },
            {
              "__type": "Link",
              "__tag": 4049,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "gh-26846"
                }
              ],
              "url": "https://github.com/numpy/numpy/pull/26846",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ")"
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "Text",
          "__tag": 4046,
          "value": "The "
        },
        {
          "__type": "InlineCode",
          "__tag": 4051,
          "value": "numpy.printoptions"
        },
        {
          "__type": "Text",
          "__tag": 4046,
          "value": " context manager is now thread and async-safe"
        }
      ],
      "level": 2,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "Starting from the 2.1 release, PEP 484 type annotations have been included for the functions and convenience classes in "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "numpy.polynomial"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " and its sub-packages."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "("
            },
            {
              "__type": "Link",
              "__tag": 4049,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "gh-26897"
                }
              ],
              "url": "https://github.com/numpy/numpy/pull/26897",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ")"
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "Text",
          "__tag": 4046,
          "value": "Type hinting "
        },
        {
          "__type": "InlineCode",
          "__tag": 4051,
          "value": "numpy.polynomial"
        }
      ],
      "level": 2,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "The type annotations for "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "numpy.dtypes"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " are now a better reflection of the runtime: The "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "numpy.dtype"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " type-aliases have been replaced with specialized "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "dtype"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " "
            },
            {
              "__type": "Emphasis",
              "__tag": 4047,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "subtypes"
                }
              ]
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ", and the previously missing annotations for "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "numpy.dtypes.StringDType"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " have been added."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "("
            },
            {
              "__type": "Link",
              "__tag": 4049,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "gh-27008"
                }
              ],
              "url": "https://github.com/numpy/numpy/pull/27008",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ")"
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "Text",
          "__tag": 4046,
          "value": "Improved "
        },
        {
          "__type": "InlineCode",
          "__tag": 4051,
          "value": "numpy.dtypes"
        },
        {
          "__type": "Text",
          "__tag": 4046,
          "value": " type hints"
        }
      ],
      "level": 2,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "BulletList",
          "__tag": 4053,
          "ordered": false,
          "start": 1,
          "children": [
            {
              "__type": "ListItem",
              "__tag": 4054,
              "children": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "numpy.save"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " now uses pickle protocol version 4 for saving arrays with   object dtype, which allows for pickle objects larger than 4GB and improves   saving speed by about 5% for large arrays."
                    }
                  ]
                },
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "("
                    },
                    {
                      "__type": "Link",
                      "__tag": 4049,
                      "children": [
                        {
                          "__type": "Text",
                          "__tag": 4046,
                          "value": "gh-26388"
                        }
                      ],
                      "url": "https://github.com/numpy/numpy/pull/26388",
                      "title": ""
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ")"
                    }
                  ]
                }
              ]
            },
            {
              "__type": "ListItem",
              "__tag": 4054,
              "children": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "OpenBLAS on x86_64 and i686 is built with fewer kernels. Based on   benchmarking, there are 5 clusters of performance around these kernels:   "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "PRESCOTT NEHALEM SANDYBRIDGE HASWELL SKYLAKEX"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "."
                    }
                  ]
                },
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "("
                    },
                    {
                      "__type": "Link",
                      "__tag": 4049,
                      "children": [
                        {
                          "__type": "Text",
                          "__tag": 4046,
                          "value": "gh-27147"
                        }
                      ],
                      "url": "https://github.com/numpy/numpy/pull/27147",
                      "title": ""
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ")"
                    }
                  ]
                }
              ]
            },
            {
              "__type": "ListItem",
              "__tag": 4054,
              "children": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "OpenBLAS on windows is linked without quadmath, simplifying licensing"
                    }
                  ]
                },
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "("
                    },
                    {
                      "__type": "Link",
                      "__tag": 4049,
                      "children": [
                        {
                          "__type": "Text",
                          "__tag": 4046,
                          "value": "gh-27147"
                        }
                      ],
                      "url": "https://github.com/numpy/numpy/pull/27147",
                      "title": ""
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ")"
                    }
                  ]
                }
              ]
            },
            {
              "__type": "ListItem",
              "__tag": 4054,
              "children": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "Due to a regression in OpenBLAS on windows, the performance improvements when   using multiple threads for OpenBLAS 0.3.26 were reverted."
                    }
                  ]
                },
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "("
                    },
                    {
                      "__type": "Link",
                      "__tag": 4049,
                      "children": [
                        {
                          "__type": "Text",
                          "__tag": 4046,
                          "value": "gh-27147"
                        }
                      ],
                      "url": "https://github.com/numpy/numpy/pull/27147",
                      "title": ""
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ")"
                    }
                  ]
                }
              ]
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "Text",
          "__tag": 4046,
          "value": "Performance improvements and changes"
        }
      ],
      "level": 1,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "The private function has been refactored along with "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "ma.cov"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " and "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "ma.corrcoef"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ". They are now significantly faster, particularly on large, masked arrays."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "("
            },
            {
              "__type": "Link",
              "__tag": 4049,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "gh-26285"
                }
              ],
              "url": "https://github.com/numpy/numpy/pull/26285",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ")"
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "InlineCode",
          "__tag": 4051,
          "value": "ma.cov"
        },
        {
          "__type": "Text",
          "__tag": 4046,
          "value": " and "
        },
        {
          "__type": "InlineCode",
          "__tag": 4051,
          "value": "ma.corrcoef"
        },
        {
          "__type": "Text",
          "__tag": 4046,
          "value": " are now significantly faster"
        }
      ],
      "level": 2,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "BulletList",
          "__tag": 4053,
          "ordered": false,
          "start": 1,
          "children": [
            {
              "__type": "ListItem",
              "__tag": 4054,
              "children": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "As "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "numpy.vecdot"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " is now a ufunc it has a less precise signature.   This is due to the limitations of ufunc's typing stub."
                    }
                  ]
                },
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "("
                    },
                    {
                      "__type": "Link",
                      "__tag": 4049,
                      "children": [
                        {
                          "__type": "Text",
                          "__tag": 4046,
                          "value": "gh-26313"
                        }
                      ],
                      "url": "https://github.com/numpy/numpy/pull/26313",
                      "title": ""
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ")"
                    }
                  ]
                }
              ]
            },
            {
              "__type": "ListItem",
              "__tag": 4054,
              "children": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "numpy.floor"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ", "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "numpy.ceil"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ", and "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "numpy.trunc"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " now won't perform   casting to a floating dtype for integer and boolean dtype input arrays."
                    }
                  ]
                },
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "("
                    },
                    {
                      "__type": "Link",
                      "__tag": 4049,
                      "children": [
                        {
                          "__type": "Text",
                          "__tag": 4046,
                          "value": "gh-26766"
                        }
                      ],
                      "url": "https://github.com/numpy/numpy/pull/26766",
                      "title": ""
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ")"
                    }
                  ]
                }
              ]
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "Text",
          "__tag": 4046,
          "value": "Changes"
        }
      ],
      "level": 1,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "A pairwise observation approach is currently used in "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "ma.corrcoef"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " to calculate the standard deviations for each pair of variables. This has been changed as it is being used to normalise the covariance, estimated using "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "ma.cov"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ", which does not consider the observations for each variable in a pairwise manner, rendering it unnecessary. The normalisation has been replaced by the more appropriate standard deviation for each variable, which significantly reduces the wall time, but will return slightly different estimates of the correlation coefficients in cases where the observations between a pair of variables are not aligned. However, it will return the same estimates in all other cases, including returning the same correlation matrix as "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "corrcoef"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " when using a masked array with no masked values."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "("
            },
            {
              "__type": "Link",
              "__tag": 4049,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "gh-26285"
                }
              ],
              "url": "https://github.com/numpy/numpy/pull/26285",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ")"
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "InlineCode",
          "__tag": 4051,
          "value": "ma.corrcoef"
        },
        {
          "__type": "Text",
          "__tag": 4046,
          "value": " may return a slightly different result"
        }
      ],
      "level": 2,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "copyto"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " now uses NEP 50 correctly and applies this to its cast safety. Python integer to NumPy integer casts and Python float to NumPy float casts are now considered \"safe\" even if assignment may fail or precision may be lost. This means the following examples change slightly:"
            }
          ]
        },
        {
          "__type": "BulletList",
          "__tag": 4053,
          "ordered": false,
          "start": 1,
          "children": [
            {
              "__type": "ListItem",
              "__tag": 4054,
              "children": [
                {
                  "__type": "DefList",
                  "__tag": 4033,
                  "children": [
                    {
                      "__type": "DefListItem",
                      "__tag": 4037,
                      "dt": {
                        "__type": "Paragraph",
                        "__tag": 4045,
                        "children": [
                          {
                            "__type": "InlineCode",
                            "__tag": 4051,
                            "value": "np.copyto(int8_arr, 1000)"
                          },
                          {
                            "__type": "Text",
                            "__tag": 4046,
                            "value": " previously performed an unsafe/same-kind cast"
                          }
                        ]
                      },
                      "dd": [
                        {
                          "__type": "Paragraph",
                          "__tag": 4045,
                          "children": [
                            {
                              "__type": "Text",
                              "__tag": 4046,
                              "value": "of the Python integer.  It will now always raise, to achieve an unsafe cast    you must pass an array or NumPy scalar."
                            }
                          ]
                        }
                      ]
                    }
                  ]
                }
              ]
            },
            {
              "__type": "ListItem",
              "__tag": 4054,
              "children": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "np.copyto(uint8_arr, 1000, casting=\"safe\")"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " will raise an OverflowError   rather than a TypeError due to same-kind casting."
                    }
                  ]
                }
              ]
            },
            {
              "__type": "ListItem",
              "__tag": 4054,
              "children": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "np.copyto(float32_arr, 1e300, casting=\"safe\")"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " will overflow to "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "inf"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "   (float32 cannot hold "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "1e300"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ") rather raising a TypeError."
                    }
                  ]
                }
              ]
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "Further, only the dtype is used when assigning NumPy scalars (or 0-d arrays), meaning that the following behaves differently:"
            }
          ]
        },
        {
          "__type": "BulletList",
          "__tag": 4053,
          "ordered": false,
          "start": 1,
          "children": [
            {
              "__type": "ListItem",
              "__tag": 4054,
              "children": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "np.copyto(float32_arr, np.float64(3.0), casting=\"safe\")"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " raises."
                    }
                  ]
                }
              ]
            },
            {
              "__type": "ListItem",
              "__tag": 4054,
              "children": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "np.coptyo(int8_arr, np.int64(100), casting=\"safe\")"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " raises.   Previously, NumPy checked whether the 100 fits the "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "int8_arr"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "."
                    }
                  ]
                }
              ]
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "This aligns "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "copyto"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ", "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "full"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ", and "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "full_like"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " with the correct NumPy 2 behavior."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "("
            },
            {
              "__type": "Link",
              "__tag": 4049,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "gh-27091"
                }
              ],
              "url": "https://github.com/numpy/numpy/pull/27091",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ")"
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "Text",
          "__tag": 4046,
          "value": "Cast-safety fixes in "
        },
        {
          "__type": "InlineCode",
          "__tag": 4051,
          "value": "copyto"
        },
        {
          "__type": "Text",
          "__tag": 4046,
          "value": " and "
        },
        {
          "__type": "InlineCode",
          "__tag": 4051,
          "value": "full"
        }
      ],
      "level": 2,
      "target": null
    }
  ],
  "local_refs": []
}