code: def test_continuous_regression_no_overlap():
      """Test regression without overlap correction, on real data."""
      tmin, tmax = -0.1, 0.5
  
      raw = mne.io.read_raw_fif(raw_fname, preload=True)
      raw.apply_proj()
  
      # a sampling of frequency where rounding and truncation yield
      # different results checks conversion from samples to times is
      # consistent across Epochs and linear_regression_raw
      with raw.info._unlock():
          raw.info["sfreq"] = 128
  
      events = mne.read_events(event_fname)
      event_id = dict(audio_l=1, audio_r=2)
  
      raw = raw.pick(raw.ch_names[:2])
  
      epochs = mne.Epochs(
          raw, events, event_id, tmin, tmax, baseline=None, reject=None
      )
  
      revokeds = linear_regression_raw(
          raw, events, event_id, tmin=tmin, tmax=tmax, reject=None
      )
  
      # Check that evokeds and revokeds are nearly equivalent
      for cond in event_id.keys():
          assert_allclose(
              revokeds[cond].data,
              epochs[cond].average().data,
              rtol=1e-15,
          )
  
      # Test events that will lead to "duplicate" errors
      old_latency = events[1, 0]
      events[1, 0] = events[0, 0]
      pytest.raises(
          ValueError,
          linear_regression_raw,
          raw,
          events,
          event_id,
          tmin,
          tmax,
      )
  
      events[1, 0] = old_latency
      events[:, 0] = range(len(events))
      pytest.raises(
          ValueError,
          linear_regression_raw,
          raw,
          events,
          event_id,
          tmin,
          tmax,
          decim=2,
      )
  
file_path: mne-python/mne/stats/tests/test_regression.py
imports: import numpy
  import pytest
  from numpy.testing import assert_allclose, assert_array_equal, assert_equal
  from scipy.signal.windows import hann
  import mne
  from mne import read_source_estimate
  from mne.datasets import testing
  from mne.io import RawArray
  from mne.stats.regression import linear_regression, linear_regression_raw
label_desc: Use image node_id 2 for calling a global function with example usage: test_continuous_regression_no_overlap() without return types