code: def seglearn_wrapper(
      func: Callable, func_name: Optional[str] = None
  ) -> FuncWrapper:
      """Wrapper enabling compatibility with seglearn functions.
  
      As [seglearn feature-functions](https://github.com/dmbee/seglearn/blob/master/seglearn/feature_functions.py)
      are vectorized along the first axis (axis=0), we need to expand our window-data.
      This wrapper converts `1D np.array` to a `2D np.array` with all the window-data in
      `axis=1`.
  
      Parameters
      ----------
      func: Callable
          The seglearn function.
      func_name: str, optional
          The name for the passed function. This will be used when constructing the output
          names.
  
      Returns
      -------
      FuncWrapper
          The wrapped seglearn function that is compatible with tsflex.
  
      """
  
      def wrap_func(x: np.ndarray):
          out = func(x.reshape(1, len(x)))
          return out.flatten()
  
      wrap_func.__name__ = "[seglearn_wrapped]__" + _get_name(func)
      output_names = _get_name(func) if func_name is None else func_name
      # A bit hacky (hard coded), bc hist is only func that returns multiple values
      if hasattr(func, "bins"):
          output_names = [
              output_names + f"_bin{idx}"
              for idx in range(1, func.bins + 1)
          ]
      return FuncWrapper(wrap_func, output_names=output_names)
  
file_path: tsflex/tsflex/features/integrations.py
imports: import importlib
  from typing import Callable, Dict, List, Optional, Union
  import numpy
  import pandas
  from .function_wrapper import FuncWrapper, _get_name
label_desc: Use image node_id 1 for calling a global function with example usage: seglearn_wrapper(func, func_name) and returns: FuncWrapper, out