class_docstr: SecureNN(server_0, server_1, server_2, prime_factory, odd_factory, **kwargs)
  
  Implementation of SecureNN from
  `Wagh et al <https://eprint.iacr.org/2018/442/>`_.
class_docstr_tok: ["SecureNN","(","server_0",",","server_1",",","server_2",",","prime_factory",",","odd_factory",",","*","*","kwargs",")","Implementation","of","SecureNN","from","`","Wagh","et","al","<","https",":","\/\/eprint.iacr.org\/2018\/442\/",">","`","_","."]
code: def reduce_max_with_argmax(self, x, axis=0):
      with tf.name_scope("reduce-max-with-argmax"):
  
          def build_comparison_tree(tensors, indices):
              assert len(tensors) == len(indices)
              if len(indices) == 1:
                  return tensors[0], indices[0]
  
              halfway = len(tensors) // 2
              tensors_left, tensors_right = (
                  tensors[:halfway],
                  tensors[halfway:],
              )
              indices_left, indices_right = (
                  indices[:halfway],
                  indices[halfway:],
              )
  
              maximum_left, argmax_left = build_comparison_tree(
                  tensors_left, indices_left
              )
              maximum_right, argmax_right = build_comparison_tree(
                  tensors_right, indices_right
              )
  
              # compute binary tensor indicating which side is greater
              greater = self.greater(maximum_left, maximum_right)
  
              # use above binary tensor to select maximum and argmax
              maximum = self.select(
                  greater, maximum_right, maximum_left
              )
              argmax = self.select(greater, argmax_right, argmax_left)
  
              return maximum, argmax
  
          tensors = self.split(x, int(x.shape[axis]), axis=axis)
          indices = [
              self.define_constant(np.array([i]))
              for i, _ in enumerate(tensors)
          ]
  
          with tf.name_scope("comparison-tree"):
              maximum, argmax = build_comparison_tree(tensors, indices)
  
          maximum = self.squeeze(maximum, axis=(axis,))
          argmax = self.squeeze(argmax, axis=(axis,))
          return maximum, argmax
  
imports: from __future__ import absolute_import
  import math
  import random
  import sys
  from typing import Optional
  from typing import Tuple
  import numpy
  import tensorflow
  from tf_encrypted.config import get_config
  from tf_encrypted.player import Player
  from tf_encrypted.protocol import memoize
  from tf_encrypted.protocol.pond import Pond
  from tf_encrypted.protocol.pond import PondMaskedTensor
  from tf_encrypted.protocol.pond import PondPrivateTensor
  from tf_encrypted.protocol.pond import PondPublicTensor
  from tf_encrypted.protocol.pond import PondTensor
  from tf_encrypted.protocol.pond import _type
  from tf_encrypted.protocol.protocol import nodes
  from tf_encrypted.protocol.securenn.odd_tensor import oddint64_factory
  from tf_encrypted.tensor import int64factory
  from tf_encrypted.tensor import native_factory
  from tf_encrypted.tensor.factory import AbstractFactory
  from tf_encrypted.tensor.factory import AbstractTensor
label_desc: Use image node_id 23 for calling the SecureNN obj's underlying member method code with example usage: obj.reduce_max_with_argmax(x, axis) and returns: maximum,  argmax, maximum,  argmax, tensors,  indices