code: def _check_inputs_dtype(X, missing_values):
      if _is_pandas_na(missing_values):
          # Allow using `pd.NA` as missing values to impute numerical arrays.
          return
      if X.dtype.kind in ("f", "i", "u") and not isinstance(
          missing_values, numbers.Real
      ):
          raise ValueError(
              "'X' and 'missing_values' types are expected to be"
              " both numerical. Got X.dtype={} and "
              " type(missing_values)={}.".format(
                  X.dtype, type(missing_values)
              )
          )
  
imports: import numbers
  import warnings
  from collections import Counter
  import numpy
  import numpy.ma
  from scipy import sparse
  from ..base import BaseEstimator, TransformerMixin, _fit_context
  from ..utils import _is_pandas_na, is_scalar_nan
  from ..utils._mask import _get_mask
  from ..utils._param_validation import MissingValues, StrOptions
  from ..utils.fixes import _mode
  from ..utils.sparsefuncs import _get_median
  from ..utils.validation import FLOAT_DTYPES, _check_feature_names_in, check_is_fitted
label_desc: Use image node_id 1 for calling a global function with example usage: _check_inputs_dtype(X, missing_values) without return types