class_docstr: Implicit matrix factorization trained with alternating least squares :cite:p:`Hu2008-li`.  This
  algorithm outputs 'predictions', but they are not on a meaningful scale.  If its input
  data contains ``rating`` values, these will be used as the 'confidence' values; otherwise,
  confidence will be 1 for every rated item.
  
  See the base class :class:`.MFPredictor` for documentation on the estimated parameters
  you can extract from a trained model.
  
  With weight :math:`w`, this function decomposes the matrix :math:`\mathbb{1}^* + Rw`, where
  :math:`\mathbb{1}^*` is an :math:`m \times n` matrix of all 1s.
  
  .. versionchanged:: 0.14
      By default, ``ImplicitMF`` ignores a ``rating`` column if one is present in the training
      data.  This can be changed through the ``use_ratings`` option.
  
  .. versionchanged:: 0.13
      In versions prior to 0.13, ``ImplicitMF`` used the rating column if it was present.
      In 0.13, we added an option to control whether or not the rating column is used; it
      initially defaulted to ``True``, but with a warning.  In 0.14 it defaults to ``False``.
  
  Args:
      features(int): the number of features to train
      iterations(int): the number of iterations to train
      reg(float): the regularization factor
      weight(float): the scaling weight for positive samples (:math:`\alpha` in :cite:p:`Hu2008-li`).
      use_ratings(bool):
          Whether to use the `rating` column, if present.  Defaults to ``False``; when ``True``,
          the values from the ``rating`` column are used, and multipled by ``weight``; if ``False``,
          ImplicitMF treats every rated user-item pair as having a rating of 1.
      method(str):
          the training method.
  
          ``'cg'`` (the default)
              Conjugate gradient method :cite:p:`Takacs2011-ix`.
          ``'lu'``
              A direct implementation of the original implicit-feedback ALS concept :cite:p:`Hu2008-li`
              using LU-decomposition to solve for the optimized matrices.
  
      rng_spec:
          Random number generator or state (see :func:`lenskit.util.random.rng`).
      progress: a :func:`tqdm.tqdm`-compatible progress bar function
code: def __str__(self):
      return "als.ImplicitMF(features={}, reg={}, w={})".format(
          self.features, self.reg, self.weight
      )
  
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 8 for calling the ImplicitMF obj's underlying member method code with example usage: obj.__str__() and returns: str