code: def test_create_sample_weights_output_using_weight_func_dict_different_series_lengths(
      weight_func, expected
  ):
      """
      Test `sample_weights` creation using `weight_func` with series of different lengths.
      """
      new_series = series.copy()
      new_series["series_2"].iloc[:3] = np.nan
      new_X_train = X_train.drop([7, 8, 9]).reset_index(drop=True)
      new_y_train_index = pd.DatetimeIndex(
          [
              "2022-01-07",
              "2022-01-08",
              "2022-01-09",
              "2022-01-10",
              "2022-01-11",
              "2022-01-12",
              "2022-01-13",
              "2022-01-10",
              "2022-01-11",
              "2022-01-12",
              "2022-01-13",
          ],
          dtype="datetime64[ns]",
          freq=None,
      )
  
      forecaster = ForecasterAutoregMultiSeriesCustom(
          regressor=LinearRegression(),
          fun_predictors=create_predictors,
          window_size=3,
          weight_func=weight_func,
      )
      results = forecaster.create_sample_weights(
          series=new_series,
          X_train=new_X_train,
          y_train_index=new_y_train_index,
      )
  
      assert np.array_equal(results, expected)
  
file_path: skforecast/skforecast/ForecasterAutoregMultiSeriesCustom/tests/test_create_sample_weights.py
imports: import re
  import pytest
  import numpy
  import pandas
  from skforecast.ForecasterAutoregMultiSeriesCustom import ForecasterAutoregMultiSeriesCustom
  from sklearn.linear_model import LinearRegression
label_desc: Use image node_id 9 for calling a global function with example usage: test_create_sample_weights_output_using_weight_func_dict_different_series_lengths(weight_func, expected) without return types