code: def point_list_to_multitrace(
      point_list: List[Dict[str, np.ndarray]],
      model: Optional[Model] = None,
  ) -> MultiTrace:
      """transform point list into MultiTrace"""
      _model = modelcontext(model)
      varnames = list(point_list[0].keys())
      with _model:
          chain = NDArray(
              model=_model, vars=[_model[vn] for vn in varnames]
          )
          chain.setup(draws=len(point_list), chain=0)
  
          # since we are simply loading a trace by hand, we need only a vacuous function for
          # chain.record() to use. This crushes the default.
          def point_fun(point):
              return [point[vn] for vn in varnames]
  
          chain.fn = point_fun
          for point in point_list:
              chain.record(point)
      return MultiTrace([chain])
  
file_path: pymc/pymc/backends/ndarray.py
imports: from typing import Any, Dict, List, Optional
  import numpy
  from pymc.backends import base
  from pymc.backends.base import MultiTrace
  from pymc.model import Model, modelcontext
label_desc: Use image node_id 2 for calling a global function with example usage: point_list_to_multitrace(point_list, model) and returns: MultiTrace, unknown