class_docstr: Strongly Convex BinaryCrossentropy loss using l2 weight regularization.
class_docstr_tok: ["Strongly","Convex","BinaryCrossentropy","loss","using","l2","weight","regularization","."]
docstr: StrongConvexBinaryCrossentropy class.
  
  Args:
    reg_lambda: Weight regularization constant
    c_arg: Penalty parameter C of the loss term
    radius_constant: constant defining the length of the radius
    from_logits: True if the input are unscaled logits. False if they are
      already scaled.
    label_smoothing: amount of smoothing to perform on labels relaxation of
      trust in labels, e.g. (1 -> 1-x, 0 -> 0+x). Note, the impact of this
      parameter's effect on privacy is not known and thus the default should
      be used.
    reduction: reduction type to use. See super class
    dtype: tf datatype to use for tensor conversions.
docstr_tok: ["StrongConvexBinaryCrossentropy","class",".","Args",":","reg_lambda",":","Weight","regularization","constant","c_arg",":","Penalty","parameter","C","of","the","loss","term","radius_constant",":","constant","defining","the","length","of","the","radius","from_logits",":","True","if","the","input","are","unscaled","logits",".","False","if","they","are","already","scaled",".","label_smoothing",":","amount","of","smoothing","to","perform","on","labels","relaxation","of","trust","in","labels",",","e.g",".","(","1","-",">","1-x",",","0","-",">","0+x",")",".","Note",",","the","impact","of","this","parameter","'s","effect","on","privacy","is","not","known","and","thus","the","default","should","be","used",".","reduction",":","reduction","type","to","use",".","See","super","class","dtype",":","tf","datatype","to","use","for","tensor","conversions","."]
code: def __init__(
      self,
      reg_lambda,
      c_arg,
      radius_constant,
      from_logits=True,
      label_smoothing=0,
      reduction=losses_utils.ReductionV2.SUM_OVER_BATCH_SIZE,
      dtype=tf.float32,
  ):
      """StrongConvexBinaryCrossentropy class.
  
      Args:
        reg_lambda: Weight regularization constant
        c_arg: Penalty parameter C of the loss term
        radius_constant: constant defining the length of the radius
        from_logits: True if the input are unscaled logits. False if they are
          already scaled.
        label_smoothing: amount of smoothing to perform on labels relaxation of
          trust in labels, e.g. (1 -> 1-x, 0 -> 0+x). Note, the impact of this
          parameter's effect on privacy is not known and thus the default should
          be used.
        reduction: reduction type to use. See super class
        dtype: tf datatype to use for tensor conversions.
      """
      if label_smoothing != 0:
          logging.warning(
              "The impact of label smoothing on privacy is unknown. "
              "Use label smoothing at your own risk as it may not "
              "guarantee privacy."
          )
  
      if reg_lambda <= 0:
          raise ValueError(
              "reg lambda: {0} must be positive".format(reg_lambda)
          )
      if c_arg <= 0:
          raise ValueError("c: {0}, should be >= 0".format(c_arg))
      if radius_constant <= 0:
          raise ValueError(
              "radius_constant: {0}, should be >= 0".format(
                  radius_constant
              )
          )
      self.dtype = dtype
      self.C = c_arg  # pylint: disable=invalid-name
      self.reg_lambda = tf.constant(reg_lambda, dtype=self.dtype)
      super().__init__(
          reduction=reduction,
          name="strongconvexbinarycrossentropy",
          from_logits=from_logits,
          label_smoothing=label_smoothing,
      )
      self.radius_constant = radius_constant
  
imports: import tensorflow.compat.v1
  from tensorflow.compat.v1.python.framework import ops
  from tensorflow.compat.v1.python.keras import losses
  from tensorflow.compat.v1.python.keras.regularizers import L1L2
  from tensorflow.compat.v1.python.keras.utils import losses_utils
  from tensorflow.compat.v1.python.platform import tf_logging
label_desc: Use image node_id 1 to create a new StrongConvexBinaryCrossentropy object from inherited base classes: losses, StrongConvexMixin with example: obj = StrongConvexBinaryCrossentropy(reg_lambda, c_arg, radius_constant, from_logits, label_smoothing, reduction, dtype)