code: def _extend(M, sym):
      """Extend window by 1 sample if needed for DFT-even symmetry"""
      if not sym:
          return M + 1, True
      else:
          return M, False
  
imports: import warnings
  import cupy
  import numpy
label_desc: Use image node_id 2 for calling a global function with example usage: _extend(M, sym) and returns: unknown,  True, M,  False