code: def to_tuple(x: Any) -> Tuple[Any, ...]:
      """Convert the input to a tuple if necessary.
  
      Parameters
      ----------
      x : Any
          The input that needs to be converted into a tuple.
  
      Returns
      -------
      List
          A tuple of `x` if `x` wasn't a tuple yet, otherwise `x`.
  
      """
      if not isinstance(x, tuple):
          return (x,)
      return x
  
file_path: tsflex/tsflex/utils/data.py
imports: import itertools
  import os
  from pathlib import Path
  from typing import Any, Dict, Iterable, Iterator, List, Tuple, Union
  import numpy
  import pandas
label_desc: Use image node_id 4 for calling a global function with example usage: to_tuple(x) and returns: x, x