numpy.asarray_chkfinite(a, dtype=None, order=None) [source]
Convert the input to an array, checking for NaNs or Infs. Parameters:
a : array_like Input data, in any form that can be converted to an array. This includes lists, lists of tuples, tuples, tuples of tuples, tuples of lists and ndarrays. Success requires no NaNs or Infs. dtype : data-type, optional By default, the data-type is inferred from the input data. order : {?C?, ?F?}, optional Whether to use row-major (C-style) or col