code: def nanmean(
      a: np.ndarray,
      /,
      *,
      axis: Optional[Union[int, Tuple[int]]] = None,
      keepdims: bool = False,
      dtype: Optional[np.dtype] = None,
      out: Optional[np.ndarray] = None,
  ) -> np.ndarray:
      if isinstance(axis, list):
          axis = tuple(axis)
      return np.nanmean(
          a, axis=axis, keepdims=keepdims, dtype=dtype, out=out
      )
  
imports: from typing import Optional, Union, Tuple, Sequence
  import numpy
  import math
  import ivy
  from ivy.func_wrapper import with_unsupported_dtypes
  from .None import backend_version
  from ..statistical import _infer_dtype
  from copy import deepcopy
label_desc: Use image node_id 3 for calling a global function with example usage: nanmean() and returns: np