class_docstr: Factorization Machine (aka FM).
  
  This class implements L2-regularized arbitrary order FM model with logistic
  loss and gradient-based optimization.
  
  Only binary classification with 0/1 labels supported.
  
  See TFFMBaseModel and TFFMCore docs for details about parameters.
docstr: Predict using the FM model
  
  Parameters
  ----------
  X : {numpy.array, scipy.sparse.csr_matrix}, shape = (n_samples, n_features)
      Samples.
  pred_batch_size : int batch size for prediction (default None)
  
  Returns
  -------
  predictions : array, shape = (n_samples,)
      Returns predicted values.
docstr_tok: ["Predict","using","the","FM","model","Parameters","--","--","--","--","--","X",":","{","numpy.array",",","scipy.sparse.csr_matrix","}",",","shape","=","(","n_samples",",","n_features",")","Samples",".","pred_batch_size",":","int","batch","size","for","prediction","(","default","None",")","Returns","--","--","--","-","predictions",":","array",",","shape","=","(","n_samples",",",")","Returns","predicted","values","."]
code: def predict(self, X, pred_batch_size=None):
      """Predict using the FM model
  
      Parameters
      ----------
      X : {numpy.array, scipy.sparse.csr_matrix}, shape = (n_samples, n_features)
          Samples.
      pred_batch_size : int batch size for prediction (default None)
  
      Returns
      -------
      predictions : array, shape = (n_samples,)
          Returns predicted values.
      """
      raw_output = self.decision_function(X, pred_batch_size)
      predictions = (raw_output > 0).astype(int)
      return predictions
  
file_path: tffm/tffm/models.py
imports: import numpy
  from .base import TFFMBaseModel
  from .utils import loss_logistic, loss_mse, sigmoid
label_desc: Use image node_id 4 for calling the TFFMClassifier obj's underlying member method code with example usage: obj.predict(X, pred_batch_size) and returns: predictions