code: def run_metocean_forecasting_problem(
      train_file_path,
      test_file_path,
      forecast_length=1,
      visualization=False,
      timeout=5,
  ):
      # Prepare data for train and test
      ssh_history, ws_history, ssh_obs = prepare_input_data(
          train_file_path, test_file_path
      )
  
      historical_data = {
          "ws": ws_history,  # additional variable
          "ssh": ssh_history,  # target variable
      }
  
      fedot = Fedot(
          problem="ts_forecasting",
          task_params=TsForecastingParams(
              forecast_length=forecast_length
          ),
          timeout=timeout,
          logging_level=logging.FATAL,
      )
  
      pipeline = fedot.fit(features=historical_data, target=ssh_history)
      fedot.forecast(historical_data)
      metric = fedot.get_metrics(target=ssh_obs)
  
      if visualization:
          pipeline.show()
          fedot.plot_prediction(target="ssh")
  
      fedot.history.save("saved_ts_history.json")
  
      return metric
  
file_path: FEDOT/cases/metocean_forecasting_problem.py
imports: import logging
  import os
  import numpy
  import pandas
  from fedot import Fedot
  from fedot.core.repository.tasks import TsForecastingParams
  from fedot.core.utils import fedot_project_root
label_desc: Use image node_id 2 for calling a global function with example usage: run_metocean_forecasting_problem(train_file_path, test_file_path, forecast_length, visualization, timeout) and returns: metric