polars.Series.is_infinite

Series.is_infinite() polars.internals.series.Series

Get mask of infinite values if Series dtype is Float.

Returns
Boolean Series

Examples

>>> import numpy as np
>>> s = pl.Series("a", [1.0, 2.0, np.inf])
>>> s.is_infinite()
shape: (3,)
Series: 'a' [bool]
[
        false
        false
        true
]