code: def _times_to_delays(tmin, tmax, sfreq):
      """Convert a tmin/tmax in seconds to delays."""
      # Convert seconds to samples
      delays = np.arange(
          int(np.round(tmin * sfreq)), int(np.round(tmax * sfreq) + 1)
      )
      return delays
  
imports: import numbers
  import numpy
  from scipy.stats import pearsonr
  from ..fixes import pinv
  from ..utils import _validate_type, fill_doc, verbose
  from .base import BaseEstimator, _check_estimator, get_coef
  from .time_delaying_ridge import TimeDelayingRidge
label_desc: Use image node_id 2 for calling a global function with example usage: _times_to_delays(tmin, tmax, sfreq) and returns: delays