code: def _make_drift(drift_model, frame_times, order, high_pass):
      """Create the drift matrix.
  
      Parameters
      ----------
      drift_model : {'polynomial', 'cosine', None},
          string that specifies the desired drift model
  
      frame_times : array of shape(n_scans),
          list of values representing the desired TRs
  
      order : int, optional,
          order of the drift model (in case it is polynomial)
  
      high_pass : float, optional,
          high-pass frequency in case of a cosine model (in Hz)
  
      Returns
      -------
      drift : array of shape(n_scans, n_drifts),
          the drift matrix
  
      names : list of length(n_drifts),
          the associated names
  
      """
      if isinstance(drift_model, str):
          drift_model = drift_model.lower()  # for robust comparisons
      if drift_model == "polynomial":
          drift = _poly_drift(order, frame_times)
      elif drift_model == "cosine":
          drift = create_cosine_drift(high_pass, frame_times)
      elif drift_model is None:
          drift = _none_drift(frame_times)
      else:
          raise NotImplementedError(
              f"Unknown drift model {drift_model!r}"
          )
      names = [f"drift_{int(k)}" for k in range(1, drift.shape[1])]
      names.append("constant")
      return drift, names
  
file_path: nilearn/nilearn/glm/first_level/design_matrix.py
imports: import sys
  from warnings import warn
  import numpy
  import pandas
  from nilearn._utils import fill_doc
  from nilearn.glm._utils import full_rank
  from nilearn.glm.first_level.experimental_paradigm import check_events, handle_modulation_of_duplicate_events
  from nilearn.glm.first_level.hemodynamic_models import compute_regressor, orthogonalize
label_desc: Use image node_id 4 for calling a global function with example usage: _make_drift(drift_model, frame_times, order, high_pass) and returns: drift,  names