code: def _get_legen_der(xx, n_coeff=100):
      """Get Legendre polynomial derivatives expanded about x."""
      coeffs = np.empty((len(xx), n_coeff, 3))
      for c, x in zip(coeffs, xx):
          p0s, p0ds, p0dds = c[:, 0], c[:, 1], c[:, 2]
          p0s[:2] = [1.0, x]
          p0ds[:2] = [0.0, 1.0]
          p0dds[:2] = [0.0, 0.0]
          for n in range(2, n_coeff):
              p0s[n], p0ds[n], p0dds[n] = _next_legen_der(
                  n,
                  x,
                  p0s[n - 1],
                  p0s[n - 2],
                  p0ds[n - 1],
                  p0dds[n - 1],
              )
      return coeffs
  
file_path: mne-python/mne/forward/_lead_dots.py
imports: import os
  import os.path
  import numpy
  from numpy.polynomial import legendre
  from ..parallel import parallel_func
  from ..utils import _get_extra_data_path, fill_doc, logger, verbose
label_desc: Use image node_id 3 for calling a global function with example usage: _get_legen_der(xx, n_coeff) and returns: coeffs