class_docstr: Wrapper class for GPy Gaussian Process classification models.
class_docstr_tok: ["Wrapper","class","for","GPy","Gaussian","Process","classification","models","."]
docstr: Perform prediction for a batch of inputs.
  
  :param x: Input samples.
  :param logits: `True` if the prediction should be done without squashing function.
  :return: Array of predictions of shape `(nb_inputs, nb_classes)`.
docstr_tok: ["Perform","prediction","for","a","batch","of","inputs",".",":","param","x",":","Input","samples",".",":","param","logits",":","`","True","`","if","the","prediction","should","be","done","without","squashing","function",".",":","return",":","Array","of","predictions","of","shape","`","(","nb_inputs",",","nb_classes",")","`","."]
code: def predict(
      self, x: np.ndarray, logits: bool = False, **kwargs
  ) -> np.ndarray:
      """
      Perform prediction for a batch of inputs.
  
      :param x: Input samples.
      :param logits: `True` if the prediction should be done without squashing function.
      :return: Array of predictions of shape `(nb_inputs, nb_classes)`.
      """
      # Apply preprocessing
      x_preprocessed, _ = self._apply_preprocessing(
          x, y=None, fit=False
      )
  
      # Perform prediction
      out = np.zeros((np.shape(x_preprocessed)[0], 2))
      if logits:
          # output the non-squashed version
          out[:, 0] = self.model.predict_noiseless(x_preprocessed)[
              0
          ].reshape(-1)
          out[:, 1] = -1.0 * out[:, 0]
      else:
          # output normal prediction, scale up to two values
          out[:, 0] = self.model.predict(x_preprocessed)[0].reshape(-1)
          out[:, 1] = 1.0 - out[:, 0]
  
      # Apply postprocessing
      predictions = self._apply_postprocessing(preds=out, fit=False)
  
      return predictions
  
file_path: adversarial-robustness-toolbox/art/estimators/classification/GPy.py
imports: from __future__ import absolute_import, division, print_function, unicode_literals
  import logging
  import os
  from typing import List, Optional, Union, Tuple, TYPE_CHECKING
  import numpy
  from art.estimators.classification.classifier import ClassifierClassLossGradients
  from art import config
label_desc: Use image node_id 5 for calling the GPyGaussianProcessClassifier obj's underlying member method code with example usage: obj.predict(x, logits) and returns: predictions