class_docstr: Biased matrix factorization trained with alternating least squares :cite:p:`Zhou2008-bj`.  This
  is a prediction-oriented algorithm suitable for explicit feedback data, using the alternating
  least squares approach to compute :math:`P` and :math:`Q` to minimize the regularized squared
  reconstruction error of the ratings matrix.
  
  It provides two solvers for the optimization step (the `method` parameter):
  
  ``'cd'`` (the default)
      Coordinate descent :cite:p:`Takacs2011-ix`, adapted for a separately-trained bias model and
      to use weighted regularization as in the original ALS paper :cite:p:`Zhou2008-bj`.
  ``'lu'``
      A direct implementation of the original ALS :cite:p:`Zhou2008-bj` using LU-decomposition
      to solve for the optimized matrices.
  
  See the base class :class:`.MFPredictor` for documentation on
  the estimated parameters you can extract from a trained model.
  
  Args:
      features(int): the number of features to train
      iterations(int): the number of iterations to train
      reg(float): the regularization factor; can also be a tuple ``(ureg, ireg)`` to
          specify separate user and item regularization terms.
      damping(float): damping factor for the underlying bias.
      bias(bool or :class:`Bias`): the bias model.  If ``True``, fits a :class:`Bias` with
          damping ``damping``.
      method(str): the solver to use (see above).
      rng_spec:
          Random number generator or state (see :func:`seedbank.numpy_rng`).
      progress: a :func:`tqdm.tqdm`-compatible progress bar function
code: def _initial_model(self, ratings):
      # transform ratings using offsets
      if self.bias:
          _logger.info("[%s] normalizing ratings", self.timer)
          ratings = self.bias.transform(ratings)
  
      "Initialize a model and build contexts."
      rmat, users, items = sparse_ratings(ratings)
      n_users = len(users)
      n_items = len(items)
  
      _logger.debug("setting up contexts")
      trmat = rmat.transpose()
  
      _logger.debug("initializing item matrix")
      imat = self.rng.standard_normal((n_items, self.features))
      imat /= np.linalg.norm(imat, axis=1).reshape((n_items, 1))
      _logger.debug("|Q|: %f", np.linalg.norm(imat, "fro"))
      _logger.debug("initializing user matrix")
      umat = self.rng.standard_normal((n_users, self.features))
      umat /= np.linalg.norm(umat, axis=1).reshape((n_users, 1))
      _logger.debug("|P|: %f", np.linalg.norm(umat, "fro"))
  
      return PartialModel(users, items, umat, imat), rmat, trmat
  
imports: import logging
  from collections import namedtuple
  import numpy
  from numba import njit, prange
  from csr import CSR
  from seedbank import numpy_rng
  from .bias import Bias
  from .mf_common import MFPredictor
  from ..data import sparse_ratings
  from ..None import util
  from ..math.solve import _dposv
label_desc: Use image node_id 5 for calling the BiasedMF obj's underlying member method code with example usage: obj._initial_model(ratings) and returns: PartialModel,  rmat,  trmat