def fit(<EOL>self,<EOL>interactions,<EOL>user_features=None,<EOL>item_features=None,<EOL>sample_weight=None,<EOL>epochs=<NUM_LIT:1>,<EOL>num_threads=<NUM_LIT:1>,<EOL>verbose=False,<EOL>):
<EOL>self._reset_state()<EOL>return self.fit_partial(<EOL>interactions,<EOL>user_features=user_features,<EOL>item_features=item_features,<EOL>sample_weight=sample_weight,<EOL>epochs=epochs,<EOL>num_threads=num_threads,<EOL>verbose=verbose,<EOL>)<EOL>
Fit the model.

For details on how to use feature matrices, see the documentation
on the :class:`lightfm.LightFM` class.

Arguments
---------

interactions: np.float32 coo_matrix of shape [n_users, n_items]
     the matrix containing
     user-item interactions. Will be converted to
     numpy.float32 dtype if it is not of that type.
user_features: np.float32 csr_matrix of shape [n_users, n_user_features], optional
     Each row contains that user's weights over features.
item_features: np.float32 csr_matrix of shape [n_items, n_item_features], optional
     Each row contains that item's weights over features.
sample_weight: np.float32 coo_matrix of shape [n_users, n_items], optional
     matrix with entries expressing weights of individual
     interactions from the interactions matrix.
     Its row and col arrays must be the same as
     those of the interactions matrix. For memory
     efficiency its possible to use the same arrays
     for both weights and interaction matrices.
     Defaults to weight 1.0 for all interactions.
     Not implemented for the k-OS loss.
epochs: int, optional
     number of epochs to run
num_threads: int, optional
     Number of parallel computation threads to use. Should
     not be higher than the number of physical cores.
verbose: bool, optional
     whether to print progress messages.
     If `tqdm` is installed, a progress bar will be displayed instead.

Returns
-------

LightFM instance
    the fitted model