code: def validate_fftn(tensor, s=None, axes=None, norm=None):
      if axes is None:
          if s is None:
              axes = tuple(range(tensor.ndim))
          else:
              axes = tuple(range(len(s)))
      else:
          for axis in axes:
              validate_axis(tensor.ndim, axis)
          if len(set(axes)) < len(axes):
              raise ValueError("Duplicate axes not allowed")
  
      if norm is not None and norm not in ("ortho",):
          raise ValueError(
              f'Invalid norm value {norm}, should be None or "ortho"'
          )
  
      return axes
  
imports: from collections.abc import Iterable
  from ...core import recursive_tile
  from ...serialization.serializables import FieldTypes, KeyField, StringField, Int32Field, Int64Field, TupleField
  from ...utils import has_unknown_shape
  from ..utils import validate_axis, decide_chunk_sizes
  from ..operands import TensorHasInput, TensorOperandMixin
  from ..array_utils import get_array_module
label_desc: Use image node_id 2 for calling a global function with example usage: validate_fftn(tensor, s, axes, norm) and returns: axes