This is a pre-release version (latest).Go to latest (2.4.4)
{ } Raw JSON

bundles / numpy latest / numpy / polynomial / polyutils / _as_int

function

numpy.polynomial.polyutils:_as_int

source: build-install/usr/lib/python3.14/site-packages/numpy/polynomial/polyutils.py:703

Signature

def _as_int(x, desc)

Summary

Like operator.index, but emits a custom exception when passed an incorrect type

Parameters

x : int-like

Value to interpret as an integer

desc : str

description to include in any error message

Raises

TypeError : if x is a float or non-numeric

Aliases

  • numpy.polynomial.polyutils._as_int