code: def test_ssd_pipeline():
      """Test if SSD works in a pipeline."""
      pytest.importorskip("sklearn")
      from sklearn.pipeline import Pipeline
  
      sf = 250
      X, A, S = simulate_data(
          n_trials=100, n_channels=20, n_samples=500
      )
      X_e = np.reshape(X, (100, 20, 500))
      # define bynary random output
      y = np.random.randint(2, size=100)
  
      info = create_info(ch_names=20, sfreq=sf, ch_types="eeg")
  
      filt_params_signal = dict(
          l_freq=freqs_sig[0],
          h_freq=freqs_sig[1],
          l_trans_bandwidth=4,
          h_trans_bandwidth=4,
      )
      filt_params_noise = dict(
          l_freq=freqs_noise[0],
          h_freq=freqs_noise[1],
          l_trans_bandwidth=4,
          h_trans_bandwidth=4,
      )
      ssd = SSD(info, filt_params_signal, filt_params_noise)
      csp = CSP()
      pipe = Pipeline([("SSD", ssd), ("CSP", csp)])
      pipe.set_params(SSD__n_components=5)
      pipe.set_params(CSP__n_components=2)
      out = pipe.fit_transform(X_e, y)
      assert out.shape == (100, 2)
      assert pipe.get_params()["SSD__n_components"] == 5
  
file_path: mne-python/mne/decoding/tests/test_ssd.py
imports: import numpy
  import pytest
  from numpy.testing import assert_array_almost_equal, assert_array_equal
  from mne import create_info, io
  from mne.decoding import CSP
  from mne.decoding.ssd import SSD
  from mne.filter import filter_data
  from mne.time_frequency import psd_array_welch
label_desc: Use image node_id 4 for calling a global function with example usage: test_ssd_pipeline() without return types