{
  "__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:1.24.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": "The NumPy 1.24.0 release continues the ongoing work to improve the handling and promotion of dtypes, increase the execution speed, and clarify the documentation.  There are also a large number of new and expired deprecations due to changes in promotion and cleanups. This might be called a deprecation release. Highlights 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": "Many new deprecations, check them out."
                    }
                  ]
                }
              ]
            },
            {
              "__type": "ListItem",
              "__tag": 4054,
              "children": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "Many expired deprecations,"
                    }
                  ]
                }
              ]
            },
            {
              "__type": "ListItem",
              "__tag": 4054,
              "children": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "New F2PY features and fixes."
                    }
                  ]
                }
              ]
            },
            {
              "__type": "ListItem",
              "__tag": 4054,
              "children": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "New \"dtype\" and \"casting\" keywords for stacking functions."
                    }
                  ]
                }
              ]
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "See below for the details,"
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "This release supports Python versions 3.8-3.11."
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "Text",
          "__tag": 4046,
          "value": "NumPy 1.24 Release Notes"
        }
      ],
      "level": 0,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [],
      "title": [
        {
          "__type": "Text",
          "__tag": 4046,
          "value": "Deprecations"
        }
      ],
      "level": 1,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "The "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "numpy.fastCopyAndTranspose"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " function has been deprecated. Use the corresponding copy and transpose methods directly      "
            }
          ]
        },
        {
          "__type": "Code",
          "__tag": 4050,
          "value": "arr.T.copy()",
          "execution_status": null
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "The underlying C function "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "PyArray_CopyAndTranspose"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " has also been deprecated from the NumPy C-API."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "("
            },
            {
              "__type": "Link",
              "__tag": 4049,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "gh-22313"
                }
              ],
              "url": "https://github.com/numpy/numpy/pull/22313",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ")"
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "Text",
          "__tag": 4046,
          "value": "Deprecate fastCopyAndTranspose and PyArray_CopyAndTranspose"
        }
      ],
      "level": 2,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "Attempting a conversion from a Python integer to a NumPy value will now always check whether the result can be represented by NumPy.  This means the following examples will fail in the future and give a "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "DeprecationWarning"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " now      "
            }
          ]
        },
        {
          "__type": "Code",
          "__tag": 4050,
          "value": "np.uint8(-1)\nnp.array([3000], dtype=np.int8)",
          "execution_status": null
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "Many of these did succeed before.  Such code was mainly useful for unsigned integers with negative values such as "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "np.uint8(-1)"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " giving "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "np.iinfo(np.uint8).max"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "Note that conversion between NumPy integers is unaffected, so that "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "np.array(-1).astype(np.uint8)"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " continues to work and use C integer overflow logic.  For negative values, it will also work to view the array: "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "np.array(-1, dtype=np.int8).view(np.uint8)"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ". In some cases, using "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "np.iinfo(np.uint8).max"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " or "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "val % 2**8"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " may also work well."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "In rare cases input data may mix both negative values and very large unsigned values (i.e. "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "-1"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " and "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "2**63"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ").  There it is unfortunately necessary to use "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "%"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " on the Python value or use signed or unsigned conversion depending on whether negative values are expected."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "("
            },
            {
              "__type": "Link",
              "__tag": 4049,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "gh-22385"
                }
              ],
              "url": "https://github.com/numpy/numpy/pull/22385",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ")"
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "Text",
          "__tag": 4046,
          "value": "Conversion of out-of-bound Python integers"
        }
      ],
      "level": 2,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "The "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "numpy.msort"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " function is deprecated. Use "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "np.sort(a, axis=0)"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " instead."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "("
            },
            {
              "__type": "Link",
              "__tag": 4049,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "gh-22456"
                }
              ],
              "url": "https://github.com/numpy/numpy/pull/22456",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ")"
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "Text",
          "__tag": 4046,
          "value": "Deprecate "
        },
        {
          "__type": "InlineCode",
          "__tag": 4051,
          "value": "msort"
        }
      ],
      "level": 2,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "The scalar type aliases ending in a 0 bit size: "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "np.object0"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ", "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "np.str0"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ", "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "np.bytes0"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ", "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "np.void0"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ", "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "np.int0"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ", "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "np.uint0"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " as well as "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "np.bool8"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " are now deprecated and will eventually be removed."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "("
            },
            {
              "__type": "Link",
              "__tag": 4049,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "gh-22607"
                }
              ],
              "url": "https://github.com/numpy/numpy/pull/22607",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ")"
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "InlineCode",
          "__tag": 4051,
          "value": "np.str0"
        },
        {
          "__type": "Text",
          "__tag": 4046,
          "value": " and similar are now deprecated"
        }
      ],
      "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": "normed"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " keyword argument has been removed from   "
                    },
                    {
                      "__type": "InlineRole",
                      "__tag": 4003,
                      "value": "np.histogram",
                      "domain": null,
                      "role": null,
                      "inventory": null
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ", "
                    },
                    {
                      "__type": "InlineRole",
                      "__tag": 4003,
                      "value": "np.histogram2d",
                      "domain": null,
                      "role": null,
                      "inventory": null
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ", and "
                    },
                    {
                      "__type": "InlineRole",
                      "__tag": 4003,
                      "value": "np.histogramdd",
                      "domain": null,
                      "role": null,
                      "inventory": null
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ".   Use "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "density"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " instead.  If "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "normed"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " was passed by   position, "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "density"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " is now used."
                    }
                  ]
                },
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "("
                    },
                    {
                      "__type": "Link",
                      "__tag": 4049,
                      "children": [
                        {
                          "__type": "Text",
                          "__tag": 4046,
                          "value": "gh-21645"
                        }
                      ],
                      "url": "https://github.com/numpy/numpy/pull/21645",
                      "title": ""
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ")"
                    }
                  ]
                }
              ]
            },
            {
              "__type": "ListItem",
              "__tag": 4054,
              "children": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "Ragged array creation will now always raise a "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "ValueError"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " unless   "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "dtype=object"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " is passed.  This includes very deeply nested sequences."
                    }
                  ]
                },
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "("
                    },
                    {
                      "__type": "Link",
                      "__tag": 4049,
                      "children": [
                        {
                          "__type": "Text",
                          "__tag": 4046,
                          "value": "gh-22004"
                        }
                      ],
                      "url": "https://github.com/numpy/numpy/pull/22004",
                      "title": ""
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ")"
                    }
                  ]
                }
              ]
            },
            {
              "__type": "ListItem",
              "__tag": 4054,
              "children": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "Support for Visual Studio 2015 and earlier has been removed."
                    }
                  ]
                }
              ]
            },
            {
              "__type": "ListItem",
              "__tag": 4054,
              "children": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "Support for the Windows Interix POSIX interop layer has been removed."
                    }
                  ]
                },
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "("
                    },
                    {
                      "__type": "Link",
                      "__tag": 4049,
                      "children": [
                        {
                          "__type": "Text",
                          "__tag": 4046,
                          "value": "gh-22139"
                        }
                      ],
                      "url": "https://github.com/numpy/numpy/pull/22139",
                      "title": ""
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ")"
                    }
                  ]
                }
              ]
            },
            {
              "__type": "ListItem",
              "__tag": 4054,
              "children": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "Support for Cygwin < 3.3 has been removed."
                    }
                  ]
                },
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "("
                    },
                    {
                      "__type": "Link",
                      "__tag": 4049,
                      "children": [
                        {
                          "__type": "Text",
                          "__tag": 4046,
                          "value": "gh-22159"
                        }
                      ],
                      "url": "https://github.com/numpy/numpy/pull/22159",
                      "title": ""
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ")"
                    }
                  ]
                }
              ]
            },
            {
              "__type": "ListItem",
              "__tag": 4054,
              "children": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "The mini() method of "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "np.ma.MaskedArray"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " has been removed. Use either   "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "np.ma.MaskedArray.min()"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " or "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "np.ma.minimum.reduce()"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "."
                    }
                  ]
                }
              ]
            },
            {
              "__type": "ListItem",
              "__tag": 4054,
              "children": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "The single-argument form of "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "np.ma.minimum"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " and "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "np.ma.maximum"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " has been   removed. Use "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "np.ma.minimum.reduce()"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " or "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "np.ma.maximum.reduce()"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "   instead."
                    }
                  ]
                },
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "("
                    },
                    {
                      "__type": "Link",
                      "__tag": 4049,
                      "children": [
                        {
                          "__type": "Text",
                          "__tag": 4046,
                          "value": "gh-22228"
                        }
                      ],
                      "url": "https://github.com/numpy/numpy/pull/22228",
                      "title": ""
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ")"
                    }
                  ]
                }
              ]
            },
            {
              "__type": "ListItem",
              "__tag": 4054,
              "children": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "Passing dtype instances other than the canonical (mainly native byte-order)   ones to "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "dtype="
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " or "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "signature="
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " in ufuncs will now raise a   "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "TypeError"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ".  We recommend passing the strings "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "\"int8\""
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " or scalar types   "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "np.int8"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " since the byte-order, datetime/timedelta unit, etc. are never   enforced.  (Initially deprecated in NumPy 1.21.)"
                    }
                  ]
                },
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "("
                    },
                    {
                      "__type": "Link",
                      "__tag": 4049,
                      "children": [
                        {
                          "__type": "Text",
                          "__tag": 4046,
                          "value": "gh-22540"
                        }
                      ],
                      "url": "https://github.com/numpy/numpy/pull/22540",
                      "title": ""
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ")"
                    }
                  ]
                }
              ]
            },
            {
              "__type": "ListItem",
              "__tag": 4054,
              "children": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "The "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "dtype="
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " argument to comparison ufuncs is now applied correctly.  That   means that only "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "bool"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " and "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "object"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " are valid values and "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "dtype=object"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "   is enforced."
                    }
                  ]
                },
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "("
                    },
                    {
                      "__type": "Link",
                      "__tag": 4049,
                      "children": [
                        {
                          "__type": "Text",
                          "__tag": 4046,
                          "value": "gh-22541"
                        }
                      ],
                      "url": "https://github.com/numpy/numpy/pull/22541",
                      "title": ""
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ")"
                    }
                  ]
                }
              ]
            },
            {
              "__type": "ListItem",
              "__tag": 4054,
              "children": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "The deprecation for the aliases "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "np.object"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ", "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "np.bool"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ", "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "np.float"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ",   "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "np.complex"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ", "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "np.str"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ", and "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "np.int"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " is expired (introduces NumPy   1.20).  Some of these will now give a FutureWarning in addition to raising an   error since they will be mapped to the NumPy scalars in the future."
                    }
                  ]
                },
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "("
                    },
                    {
                      "__type": "Link",
                      "__tag": 4049,
                      "children": [
                        {
                          "__type": "Text",
                          "__tag": 4046,
                          "value": "gh-22607"
                        }
                      ],
                      "url": "https://github.com/numpy/numpy/pull/22607",
                      "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": "Compatibility notes"
        }
      ],
      "level": 1,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "numpy.ndarray.fill"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " may in some cases behave slightly different now due to the fact that the logic is aligned with item assignment      "
            }
          ]
        },
        {
          "__type": "Code",
          "__tag": 4050,
          "value": "arr = np.array([1])  # with any dtype/value\narr.fill(scalar)\n# is now identical to:\narr[0] = scalar",
          "execution_status": null
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "Previously casting may have produced slightly different answers when using values that could not be represented in the target "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "dtype"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " or when the target had "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "object"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " dtype."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "("
            },
            {
              "__type": "Link",
              "__tag": 4049,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "gh-20924"
                }
              ],
              "url": "https://github.com/numpy/numpy/pull/20924",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ")"
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "InlineCode",
          "__tag": 4051,
          "value": "array.fill(scalar)"
        },
        {
          "__type": "Text",
          "__tag": 4046,
          "value": " may behave slightly different"
        }
      ],
      "level": 2,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "Casting a dtype that includes a subarray to an object will now ensure a copy of the subarray.  Previously an unsafe view was returned      "
            }
          ]
        },
        {
          "__type": "Code",
          "__tag": 4050,
          "value": "arr = np.ones(3, dtype=[(\"f\", \"i\", 3)])\nsubarray_fields = arr.astype(object)[0]\nsubarray = subarray_fields[0]  # \"f\" field\n\nnp.may_share_memory(subarray, arr)",
          "execution_status": null
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "Is now always false.  While previously it was true for the specific cast."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "("
            },
            {
              "__type": "Link",
              "__tag": 4049,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "gh-21925"
                }
              ],
              "url": "https://github.com/numpy/numpy/pull/21925",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ")"
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "Text",
          "__tag": 4046,
          "value": "Subarray to object cast now copies"
        }
      ],
      "level": 2,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "When the "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "dtype"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " keyword argument is used with "
            },
            {
              "__type": "InlineRole",
              "__tag": 4003,
              "value": "array()",
              "domain": "py",
              "role": "func",
              "inventory": null
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " or "
            },
            {
              "__type": "InlineRole",
              "__tag": 4003,
              "value": "asarray()",
              "domain": "py",
              "role": "func",
              "inventory": null
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ", the dtype of the returned array now always exactly matches the dtype provided by the caller."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "In some cases this change means that a "
            },
            {
              "__type": "Emphasis",
              "__tag": 4047,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "view"
                }
              ]
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " rather than the input array is returned.  The following is an example for this on 64bit Linux where "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "long"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " and "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "longlong"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " are the same precision but different "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "dtypes"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "      "
            }
          ]
        },
        {
          "__type": "Code",
          "__tag": 4050,
          "value": ">>> arr = np.array([1, 2, 3], dtype=\"long\")\n>>> new_dtype = np.dtype(\"longlong\")\n>>> new = np.asarray(arr, dtype=new_dtype)\n>>> new.dtype is new_dtype\nTrue\n>>> new is arr\nFalse",
          "execution_status": null
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "Before the change, the "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "dtype"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " did not match because "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "new is arr"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " was "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "True"
            },
            {
              "__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-21995"
                }
              ],
              "url": "https://github.com/numpy/numpy/pull/21995",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ")"
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "Text",
          "__tag": 4046,
          "value": "Returned arrays respect uniqueness of dtype kwarg objects"
        }
      ],
      "level": 2,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "When an array buffer cannot be exported via DLPack a "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "BufferError"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " is now always raised where previously "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "TypeError"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " or "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "RuntimeError"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " was raised. This allows falling back to the buffer protocol or "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "__array_interface__"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " when DLPack was tried first."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "("
            },
            {
              "__type": "Link",
              "__tag": 4049,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "gh-22542"
                }
              ],
              "url": "https://github.com/numpy/numpy/pull/22542",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ")"
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "Text",
          "__tag": 4046,
          "value": "DLPack export raises "
        },
        {
          "__type": "InlineCode",
          "__tag": 4051,
          "value": "BufferError"
        }
      ],
      "level": 2,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "Ubuntu 18.04 is deprecated for GitHub actions and GCC-6 is not available on Ubuntu 20.04, so builds using that compiler are no longer tested. We still test builds using GCC-7 and GCC-8."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "("
            },
            {
              "__type": "Link",
              "__tag": 4049,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "gh-22598"
                }
              ],
              "url": "https://github.com/numpy/numpy/pull/22598",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ")"
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "Text",
          "__tag": 4046,
          "value": "NumPy builds are no longer tested on GCC-6"
        }
      ],
      "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": "The polynomial classes in the "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "numpy.polynomial"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " package have a new "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "symbol"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " attribute which is used to represent the indeterminate of the polynomial.  This can be used to change the value of the variable when printing      "
            }
          ]
        },
        {
          "__type": "Code",
          "__tag": 4050,
          "value": ">>> P_y = np.polynomial.Polynomial([1, 0, -1], symbol=\"y\")\n>>> print(P_y)\n1.0 + 0.0·y¹ - 1.0·y²",
          "execution_status": null
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "Note that the polynomial classes only support 1D polynomials, so operations that involve polynomials with different symbols are disallowed when the result would be multivariate      "
            }
          ]
        },
        {
          "__type": "Code",
          "__tag": 4050,
          "value": ">>> P = np.polynomial.Polynomial([1, -1])  # default symbol is \"x\"\n>>> P_z = np.polynomial.Polynomial([1, 1], symbol=\"z\")\n>>> P * P_z\nTraceback (most recent call last)\n   ...\nValueError: Polynomial symbols differ",
          "execution_status": null
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "The symbol can be any valid Python identifier. The default is "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "symbol=x"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ", consistent with existing behavior."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "("
            },
            {
              "__type": "Link",
              "__tag": 4049,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "gh-16154"
                }
              ],
              "url": "https://github.com/numpy/numpy/pull/16154",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ")"
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "Text",
          "__tag": 4046,
          "value": "New attribute "
        },
        {
          "__type": "InlineCode",
          "__tag": 4051,
          "value": "symbol"
        },
        {
          "__type": "Text",
          "__tag": 4046,
          "value": " added to polynomial classes"
        }
      ],
      "level": 2,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "F2PY now supports wrapping Fortran functions with:"
            }
          ]
        },
        {
          "__type": "BulletList",
          "__tag": 4053,
          "ordered": false,
          "start": 1,
          "children": [
            {
              "__type": "ListItem",
              "__tag": 4054,
              "children": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "character (e.g. "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "character x"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ")"
                    }
                  ]
                }
              ]
            },
            {
              "__type": "ListItem",
              "__tag": 4054,
              "children": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "character array (e.g. "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "character, dimension(n) :: x"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ")"
                    }
                  ]
                }
              ]
            },
            {
              "__type": "ListItem",
              "__tag": 4054,
              "children": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "character string (e.g. "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "character(len=10) x"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ")"
                    }
                  ]
                }
              ]
            },
            {
              "__type": "ListItem",
              "__tag": 4054,
              "children": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "and character string array (e.g. "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "character(len=10), dimension(n, m) :: x"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ")"
                    }
                  ]
                }
              ]
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "arguments, including passing Python unicode strings as Fortran character string arguments."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "("
            },
            {
              "__type": "Link",
              "__tag": 4049,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "gh-19388"
                }
              ],
              "url": "https://github.com/numpy/numpy/pull/19388",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ")"
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "Text",
          "__tag": 4046,
          "value": "F2PY support for Fortran "
        },
        {
          "__type": "InlineCode",
          "__tag": 4051,
          "value": "character"
        },
        {
          "__type": "Text",
          "__tag": 4046,
          "value": " strings"
        }
      ],
      "level": 2,
      "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": "numpy.show_runtime"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " has been added to display the runtime information of the machine in addition to "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "numpy.show_config"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " which displays the build-related information."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "("
            },
            {
              "__type": "Link",
              "__tag": 4049,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "gh-21468"
                }
              ],
              "url": "https://github.com/numpy/numpy/pull/21468",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ")"
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "Text",
          "__tag": 4046,
          "value": "New function "
        },
        {
          "__type": "InlineCode",
          "__tag": 4051,
          "value": "np.show_runtime"
        }
      ],
      "level": 2,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "The "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "strict"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " option is now available for "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "testing.assert_array_equal"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ". Setting "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "strict=True"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " will disable the broadcasting behaviour for scalars and ensure that input arrays have the same data type."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "("
            },
            {
              "__type": "Link",
              "__tag": 4049,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "gh-21595"
                }
              ],
              "url": "https://github.com/numpy/numpy/pull/21595",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ")"
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "InlineCode",
          "__tag": 4051,
          "value": "strict"
        },
        {
          "__type": "Text",
          "__tag": 4046,
          "value": " option for "
        },
        {
          "__type": "InlineCode",
          "__tag": 4051,
          "value": "testing.assert_array_equal"
        }
      ],
      "level": 2,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "np.unique"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " was changed in 1.21 to treat all "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "NaN"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " values as equal and return a single "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "NaN"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ". Setting "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "equal_nan=False"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " will restore pre-1.21 behavior to treat "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "NaNs"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " as unique. Defaults to "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "True"
            },
            {
              "__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-21623"
                }
              ],
              "url": "https://github.com/numpy/numpy/pull/21623",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ")"
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "Text",
          "__tag": 4046,
          "value": "New parameter "
        },
        {
          "__type": "InlineCode",
          "__tag": 4051,
          "value": "equal_nan"
        },
        {
          "__type": "Text",
          "__tag": 4046,
          "value": " added to "
        },
        {
          "__type": "InlineCode",
          "__tag": 4051,
          "value": "np.unique"
        }
      ],
      "level": 2,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "The "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "casting"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " and "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "dtype"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " keyword arguments are now available for "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "numpy.stack"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ".  To use them, write "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "np.stack(..., dtype=None, casting='same_kind')"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "."
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "InlineCode",
          "__tag": 4051,
          "value": "casting"
        },
        {
          "__type": "Text",
          "__tag": 4046,
          "value": " and "
        },
        {
          "__type": "InlineCode",
          "__tag": 4051,
          "value": "dtype"
        },
        {
          "__type": "Text",
          "__tag": 4046,
          "value": " keyword arguments for "
        },
        {
          "__type": "InlineCode",
          "__tag": 4051,
          "value": "numpy.stack"
        }
      ],
      "level": 2,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "The "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "casting"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " and "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "dtype"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " keyword arguments are now available for "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "numpy.vstack"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ".  To use them, write "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "np.vstack(..., dtype=None, casting='same_kind')"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "."
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "InlineCode",
          "__tag": 4051,
          "value": "casting"
        },
        {
          "__type": "Text",
          "__tag": 4046,
          "value": " and "
        },
        {
          "__type": "InlineCode",
          "__tag": 4051,
          "value": "dtype"
        },
        {
          "__type": "Text",
          "__tag": 4046,
          "value": " keyword arguments for "
        },
        {
          "__type": "InlineCode",
          "__tag": 4051,
          "value": "numpy.vstack"
        }
      ],
      "level": 2,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "The "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "casting"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " and "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "dtype"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " keyword arguments are now available for "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "numpy.hstack"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ".  To use them, write "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "np.hstack(..., dtype=None, casting='same_kind')"
            },
            {
              "__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-21627"
                }
              ],
              "url": "https://github.com/numpy/numpy/pull/21627",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ")"
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "InlineCode",
          "__tag": 4051,
          "value": "casting"
        },
        {
          "__type": "Text",
          "__tag": 4046,
          "value": " and "
        },
        {
          "__type": "InlineCode",
          "__tag": 4051,
          "value": "dtype"
        },
        {
          "__type": "Text",
          "__tag": 4046,
          "value": " keyword arguments for "
        },
        {
          "__type": "InlineCode",
          "__tag": 4051,
          "value": "numpy.hstack"
        }
      ],
      "level": 2,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "The singleton "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "RandomState"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " instance exposed in the "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "numpy.random"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " module is initialized at startup with the "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "MT19937"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " bit generator. The new function "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "set_bit_generator"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " allows the default bit generator to be replaced with a user-provided bit generator. This function has been introduced to provide a method allowing seamless integration of a high-quality, modern bit generator in new code with existing code that makes use of the singleton-provided random variate generating functions. The companion function "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "get_bit_generator"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " returns the current bit generator being used by the singleton "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "RandomState"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ". This is provided to simplify restoring the original source of randomness if required."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "The preferred method to generate reproducible random numbers is to use a modern bit generator in an instance of "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "Generator"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ". The function "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "default_rng"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " simplifies instantiation     "
            }
          ]
        },
        {
          "__type": "Code",
          "__tag": 4050,
          "value": ">>> rg = np.random.default_rng(3728973198)\n>>> rg.random()",
          "execution_status": null
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "The same bit generator can then be shared with the singleton instance so that calling functions in the "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "random"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " module will use the same bit generator     "
            }
          ]
        },
        {
          "__type": "Code",
          "__tag": 4050,
          "value": ">>> orig_bit_gen = np.random.get_bit_generator()\n>>> np.random.set_bit_generator(rg.bit_generator)\n>>> np.random.normal()",
          "execution_status": null
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "The swap is permanent (until reversed) and so any call to functions in the "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "random"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " module will use the new bit generator. The original can be restored if required for code to run correctly     "
            }
          ]
        },
        {
          "__type": "Code",
          "__tag": 4050,
          "value": ">>> np.random.set_bit_generator(orig_bit_gen)",
          "execution_status": null
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "("
            },
            {
              "__type": "Link",
              "__tag": 4049,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "gh-21976"
                }
              ],
              "url": "https://github.com/numpy/numpy/pull/21976",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ")"
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "Text",
          "__tag": 4046,
          "value": "The bit generator underlying the singleton RandomState can be changed"
        }
      ],
      "level": 2,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "NumPy now allows constructing structured void scalars directly by passing the "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "dtype"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " argument to "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "np.void"
            },
            {
              "__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-22316"
                }
              ],
              "url": "https://github.com/numpy/numpy/pull/22316",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ")"
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "InlineCode",
          "__tag": 4051,
          "value": "np.void"
        },
        {
          "__type": "Text",
          "__tag": 4046,
          "value": " now has a "
        },
        {
          "__type": "InlineCode",
          "__tag": 4051,
          "value": "dtype"
        },
        {
          "__type": "Text",
          "__tag": 4046,
          "value": " argument"
        }
      ],
      "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": "BulletList",
          "__tag": 4053,
          "ordered": false,
          "start": 1,
          "children": [
            {
              "__type": "ListItem",
              "__tag": 4054,
              "children": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "The generated extension modules don't use the deprecated NumPy-C API anymore"
                    }
                  ]
                }
              ]
            },
            {
              "__type": "ListItem",
              "__tag": 4054,
              "children": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "Improved "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "f2py"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " generated exception messages"
                    }
                  ]
                }
              ]
            },
            {
              "__type": "ListItem",
              "__tag": 4054,
              "children": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "Numerous bug and "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "flake8"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " warning fixes"
                    }
                  ]
                }
              ]
            },
            {
              "__type": "ListItem",
              "__tag": 4054,
              "children": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "various CPP macros that one can use within C-expressions of signature files   are prefixed with "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "f2py_"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ". For example, one should use "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "f2py_len(x)"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "   instead of "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "len(x)"
                    }
                  ]
                }
              ]
            },
            {
              "__type": "ListItem",
              "__tag": 4054,
              "children": [
                {
                  "__type": "Paragraph",
                  "__tag": 4045,
                  "children": [
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": "A new construct "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "character(f2py_len=...)"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": " is introduced to support   returning assumed length character strings (e.g. "
                    },
                    {
                      "__type": "InlineCode",
                      "__tag": 4051,
                      "value": "character(len=*)"
                    },
                    {
                      "__type": "Text",
                      "__tag": 4046,
                      "value": ") from   wrapper functions"
                    }
                  ]
                }
              ]
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "A hook to support rewriting "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "f2py"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " internal data structures after reading all its input files is introduced. This is required, for instance, for BC of SciPy support where character arguments are treated as character strings arguments in "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "C"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " expressions."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "("
            },
            {
              "__type": "Link",
              "__tag": 4049,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "gh-19388"
                }
              ],
              "url": "https://github.com/numpy/numpy/pull/19388",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ")"
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "Text",
          "__tag": 4046,
          "value": "F2PY Improvements"
        }
      ],
      "level": 2,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "Added support for SIMD extensions of zSystem (z13, z14, z15), through the universal intrinsics interface. This support leads to performance improvements for all SIMD kernels implemented using the universal intrinsics, including the following operations: rint, floor, trunc, ceil, sqrt, absolute, square, reciprocal, tanh, sin, cos, equal, not_equal, greater, greater_equal, less, less_equal, maximum, minimum, fmax, fmin, argmax, argmin, add, subtract, multiply, divide."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "("
            },
            {
              "__type": "Link",
              "__tag": 4049,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "gh-20913"
                }
              ],
              "url": "https://github.com/numpy/numpy/pull/20913",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ")"
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "Text",
          "__tag": 4046,
          "value": "IBM zSystems Vector Extension Facility (SIMD)"
        }
      ],
      "level": 2,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "In most cases, NumPy previously did not give floating point warnings or errors when these happened during casts.  For examples, casts like      "
            }
          ]
        },
        {
          "__type": "Code",
          "__tag": 4050,
          "value": "np.array([2e300]).astype(np.float32)  # overflow for float32\nnp.array([np.inf]).astype(np.int64)",
          "execution_status": null
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "Should now generally give floating point warnings.  These warnings should warn that floating point overflow occurred.  For errors when converting floating point values to integers users should expect invalid value warnings."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "Users can modify the behavior of these warnings using "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "np.errstate"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "Note that for float to int casts, the exact warnings that are given may be platform dependent.  For example      "
            }
          ]
        },
        {
          "__type": "Code",
          "__tag": 4050,
          "value": "arr = np.full(100, fill_value=1000, dtype=np.float64)\narr.astype(np.int8)",
          "execution_status": null
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "May give a result equivalent to (the intermediate cast means no warning is given)      "
            }
          ]
        },
        {
          "__type": "Code",
          "__tag": 4050,
          "value": "arr.astype(np.int64).astype(np.int8)",
          "execution_status": null
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "May return an undefined result, with a warning set      "
            }
          ]
        },
        {
          "__type": "Code",
          "__tag": 4050,
          "value": "RuntimeWarning: invalid value encountered in cast",
          "execution_status": null
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "The precise behavior is subject to the C99 standard and its implementation in both software and hardware."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "("
            },
            {
              "__type": "Link",
              "__tag": 4049,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "gh-21437"
                }
              ],
              "url": "https://github.com/numpy/numpy/pull/21437",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ")"
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "Text",
          "__tag": 4046,
          "value": "NumPy now gives floating point errors in casts"
        }
      ],
      "level": 2,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "The Fortran standard requires that variables declared with the "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "value"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " attribute must be passed by value instead of reference. F2PY now supports this use pattern correctly. So "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "integer, intent(in), value :: x"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " in Fortran codes will have correct wrappers generated."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "("
            },
            {
              "__type": "Link",
              "__tag": 4049,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "gh-21807"
                }
              ],
              "url": "https://github.com/numpy/numpy/pull/21807",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ")"
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "Text",
          "__tag": 4046,
          "value": "F2PY supports the value attribute"
        }
      ],
      "level": 2,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "The pickle format for bit generators was extended to allow each bit generator to supply its own constructor when during pickling. Previous  versions of NumPy only supported unpickling "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "Generator"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " instances created with one of the core set of bit generators supplied with NumPy. Attempting to unpickle a "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "Generator"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " that used a third-party bit generators would fail since the constructor used during the unpickling was only aware of the bit generators included in NumPy."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "("
            },
            {
              "__type": "Link",
              "__tag": 4049,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "gh-22014"
                }
              ],
              "url": "https://github.com/numpy/numpy/pull/22014",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ")"
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "Text",
          "__tag": 4046,
          "value": "Added pickle support for third-party BitGenerators"
        }
      ],
      "level": 2,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "Previously, the "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "np.arange(n, dtype=str)"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " function worked for "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "n=1"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " and "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "n=2"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ", but would raise a non-specific exception message for other values of "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "n"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ". Now, it raises a "
            },
            {
              "__type": "InlineRole",
              "__tag": 4003,
              "value": "TypeError",
              "domain": null,
              "role": null,
              "inventory": null
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " informing that "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "arange"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " does not support string dtypes      "
            }
          ]
        },
        {
          "__type": "Code",
          "__tag": 4050,
          "value": ">>> np.arange(2, dtype=str)\nTraceback (most recent call last)\n   ...\nTypeError: arange() not supported for inputs with DType <class 'numpy.dtype[str_]'>.",
          "execution_status": null
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "("
            },
            {
              "__type": "Link",
              "__tag": 4049,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "gh-22055"
                }
              ],
              "url": "https://github.com/numpy/numpy/pull/22055",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ")"
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "Text",
          "__tag": 4046,
          "value": "arange() now explicitly fails with dtype=str"
        }
      ],
      "level": 2,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "The protocols used in "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "numpy.typing.ArrayLike"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " and "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "numpy.typing.DTypeLike"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " are now properly marked as runtime checkable, making them easier to use for runtime type checkers."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "("
            },
            {
              "__type": "Link",
              "__tag": 4049,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "gh-22357"
                }
              ],
              "url": "https://github.com/numpy/numpy/pull/22357",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ")"
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "InlineCode",
          "__tag": 4051,
          "value": "numpy.typing"
        },
        {
          "__type": "Text",
          "__tag": 4046,
          "value": " protocols are now runtime checkable"
        }
      ],
      "level": 2,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [],
      "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": "InlineCode",
              "__tag": 4051,
              "value": "np.in1d"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " (used by "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "np.isin"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ") can now switch to a faster algorithm (up to >10x faster) when it is passed two integer arrays.  This is often automatically used, but you can use "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "kind=\"sort\""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " or "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "kind=\"table\""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " to force the old or new method, respectively."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "("
            },
            {
              "__type": "Link",
              "__tag": 4049,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "gh-12065"
                }
              ],
              "url": "https://github.com/numpy/numpy/pull/12065",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ")"
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "Text",
          "__tag": 4046,
          "value": "Faster version of "
        },
        {
          "__type": "InlineCode",
          "__tag": 4051,
          "value": "np.isin"
        },
        {
          "__type": "Text",
          "__tag": 4046,
          "value": " and "
        },
        {
          "__type": "InlineCode",
          "__tag": 4051,
          "value": "np.in1d"
        },
        {
          "__type": "Text",
          "__tag": 4046,
          "value": " for integer arrays"
        }
      ],
      "level": 2,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "The comparison functions ("
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "numpy.equal"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ", "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "numpy.not_equal"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ", "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "numpy.less"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ", "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "numpy.less_equal"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ", "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "numpy.greater"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " and "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "numpy.greater_equal"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ") are now much faster as they are now vectorized with universal intrinsics. For a CPU with SIMD extension AVX512BW, the performance gain is up to 2.57x, 1.65x and 19.15x for integer, float and boolean data types, respectively (with N=50000)."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "("
            },
            {
              "__type": "Link",
              "__tag": 4049,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "gh-21483"
                }
              ],
              "url": "https://github.com/numpy/numpy/pull/21483",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ")"
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "Text",
          "__tag": 4046,
          "value": "Faster comparison operators"
        }
      ],
      "level": 2,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [],
      "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": "Integer division overflow of scalars and arrays used to provide a "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "RuntimeWarning"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " and the return value was undefined leading to crashes at rare occasions      "
            }
          ]
        },
        {
          "__type": "Code",
          "__tag": 4050,
          "value": ">>> np.array([np.iinfo(np.int32).min]*10, dtype=np.int32) // np.int32(-1)\n<stdin>:1: RuntimeWarning: divide by zero encountered in floor_divide\narray([0, 0, 0, 0, 0, 0, 0, 0, 0, 0], dtype=int32)",
          "execution_status": null
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "Integer division overflow now returns the input dtype's minimum value and raise the following "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "RuntimeWarning"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "      "
            }
          ]
        },
        {
          "__type": "Code",
          "__tag": 4050,
          "value": ">>> np.array([np.iinfo(np.int32).min]*10, dtype=np.int32) // np.int32(-1)\n<stdin>:1: RuntimeWarning: overflow encountered in floor_divide\narray([-2147483648, -2147483648, -2147483648, -2147483648, -2147483648,\n       -2147483648, -2147483648, -2147483648, -2147483648, -2147483648],\n      dtype=int32)",
          "execution_status": null
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "("
            },
            {
              "__type": "Link",
              "__tag": 4049,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "gh-21506"
                }
              ],
              "url": "https://github.com/numpy/numpy/pull/21506",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ")"
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "Text",
          "__tag": 4046,
          "value": "Better reporting of integer division overflow"
        }
      ],
      "level": 2,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "When used with "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "copy=False"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ", "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "numpy.ma.masked_invalid"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " now modifies the input masked array in-place.  This makes it behave identically to "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "masked_where"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " and better matches the documentation."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "("
            },
            {
              "__type": "Link",
              "__tag": 4049,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "gh-22046"
                }
              ],
              "url": "https://github.com/numpy/numpy/pull/22046",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ")"
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "InlineCode",
          "__tag": 4051,
          "value": "masked_invalid"
        },
        {
          "__type": "Text",
          "__tag": 4046,
          "value": " now modifies the mask in-place"
        }
      ],
      "level": 2,
      "target": null
    },
    {
      "__type": "Section",
      "__tag": 4015,
      "children": [
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "The NumPy iterator available through "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "np.nditer"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " in Python and as "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "NpyIter"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " in C now supports allocating all arrays.  The iterator shape defaults to "
            },
            {
              "__type": "InlineCode",
              "__tag": 4051,
              "value": "()"
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": " in this case.  The operands dtype must be provided, since a \"common dtype\" cannot be inferred from the other inputs."
            }
          ]
        },
        {
          "__type": "Paragraph",
          "__tag": 4045,
          "children": [
            {
              "__type": "Text",
              "__tag": 4046,
              "value": "("
            },
            {
              "__type": "Link",
              "__tag": 4049,
              "children": [
                {
                  "__type": "Text",
                  "__tag": 4046,
                  "value": "gh-22457"
                }
              ],
              "url": "https://github.com/numpy/numpy/pull/22457",
              "title": ""
            },
            {
              "__type": "Text",
              "__tag": 4046,
              "value": ")"
            }
          ]
        }
      ],
      "title": [
        {
          "__type": "InlineCode",
          "__tag": 4051,
          "value": "nditer"
        },
        {
          "__type": "Text",
          "__tag": 4046,
          "value": "/"
        },
        {
          "__type": "InlineCode",
          "__tag": 4051,
          "value": "NpyIter"
        },
        {
          "__type": "Text",
          "__tag": 4046,
          "value": " allows all allocating all operands"
        }
      ],
      "level": 2,
      "target": null
    }
  ],
  "local_refs": []
}