class_docstr: This class evaluates a model against multiple attacks.
class_docstr_tok: ["This","class","evaluates","a","model","against","multiple","attacks","."]
docstr: Evaluate the accuracy of the model on adversarial examples
  
  :param x: symbolic input to model.
  :param y: symbolic variable for the label.
  :param preds_adv: symbolic variable for the prediction on an
                    adversarial example.
  :param X_test: NumPy array of test set inputs.
  :param Y_test: NumPy array of test set labels.
  :param att_type: name of the attack.
docstr_tok: ["Evaluate","the","accuracy","of","the","model","on","adversarial","examples",":","param","x",":","symbolic","input","to","model",".",":","param","y",":","symbolic","variable","for","the","label",".",":","param","preds_adv",":","symbolic","variable","for","the","prediction","on","an","adversarial","example",".",":","param","X_test",":","NumPy","array","of","test","set","inputs",".",":","param","Y_test",":","NumPy","array","of","test","set","labels",".",":","param","att_type",":","name","of","the","attack","."]
code: def eval_advs(self, x, y, preds_adv, X_test, Y_test, att_type):
      """
      Evaluate the accuracy of the model on adversarial examples
  
      :param x: symbolic input to model.
      :param y: symbolic variable for the label.
      :param preds_adv: symbolic variable for the prediction on an
                        adversarial example.
      :param X_test: NumPy array of test set inputs.
      :param Y_test: NumPy array of test set labels.
      :param att_type: name of the attack.
      """
      end = (len(X_test) // self.batch_size) * self.batch_size
  
      if self.hparams.fast_tests:
          end = 10 * self.batch_size
  
      acc = model_eval(
          self.sess,
          x,
          y,
          preds_adv,
          X_test[:end],
          Y_test[:end],
          args=self.eval_params,
      )
      self.log_value(
          "test_accuracy_%s" % att_type,
          acc,
          "Test accuracy on adversarial examples",
      )
      return acc
  
file_path: cleverhans/cleverhans_v3.1.0/examples/multigpu_advtrain/evaluator.py
imports: import logging
  import tensorflow
  from cleverhans.utils_tf import model_eval
  from cleverhans.attacks import FastGradientMethod
  from cleverhans.attacks import MadryEtAl
  from attacks_multigpu import MadryEtAlMultiGPU
label_desc: Use image node_id 3 for calling the Evaluator obj's underlying member method code with example usage: obj.eval_advs(x, y, preds_adv, X_test, Y_test, att_type) and returns: acc