
    AVhg              %       T   d Z ddlZddlmZ ddlmZ ddlmZ ddlm	Z
 ddlmZ ddlmZ dd	lmZ dd
lmZ ddlmZ ddlmZ ddlmZ ddlmZ ddlmZm Z m!Z! ddl"m#Z# ejH                  ejJ                   edg       ed      d8de#e!ejL                  f   de#e!ejN                  f   fd                            Z(  ed       ejR                  e(            Z*e(jV                  jX                  Z-de#e!ejL                  f   de#e!ejN                  f   fdZ. ej^                  dg d      Z0ejH                  ejJ                   edg       ed      d9de#e e!   ejN                  f   de#e e!   ejN                  f   de#e e!   ejb                  f   de#e e!   ejb                  f   de#e!ejb                  f   d e#e!ejb                  f   d!e#e e!   ejN                  f   d"e#e e!   ejb                  f   d#e#e e!   ejb                  f   d$e#e!ejb                  f   d%e2d&e3d'e3d(e4d)e4d*e5f d+                            Z6  ed,       ejR                  e6            Z7e6jV                  jX                  Z8de#e e!   ejN                  f   de#e e!   ejN                  f   de#e e!   ejb                  f   de#e e!   ejb                  f   de#e!ejb                  f   d e#e!ejb                  f   d!e#e e!   ejN                  f   d"e#e e!   ejb                  f   d#e#e e!   ejb                  f   d$e#e!ejb                  f   d%e2d&e3d'e3d(e4d)e4d*e5f d-Z9 ej^                  d.g d      Z:d9de#e e!   ejN                  f   de#e e!   ejN                  f   de#e e!   ejb                  f   de#e e!   ejb                  f   de#e!ejb                  f   d e#e!ejb                  f   d!e#e e!   ejN                  f   d"e#e e!   ejb                  f   d#e#e e!   ejb                  f   d$e#e!ejb                  f   d%e2d&e3d'e3d(e4d)e4d/e5f d0Z;  ed1       ejR                  e;            Z<de#e e!   ejN                  f   de#e e!   ejN                  f   de#e e!   ejb                  f   de#e e!   ejb                  f   de#e!ejb                  f   d e#e!ejb                  f   d!e#e e!   ejN                  f   d"e#e e!   ejb                  f   d#e#e e!   ejb                  f   d$e#e!ejb                  f   d%e2d&e3d'e3d(e4d)e4d/e5f d2Z=ejH                  ejJ                   ed3g       ed3      d8d4e#e e!   ejb                  f   d&e3d'e3fd5                            Z>  ed6       ejR                  e>            Z?e>jV                  jX                  Z@d4e#e e!   ejb                  f   d&e3d'e3fd7ZAy):zUPython wrappers around TensorFlow ops.

This file is MACHINE GENERATED! Do not edit.
    N)
pywrap_tfe)context)core)execute)dtypes)annotation_types)op_def_registry)ops)op_def_library)deprecated_endpoints)dispatch)	tf_export)TypeVarListAny)	Annotatedztrain.sdca_fprint)v1inputreturnc           	         t         j                   xs t        j                         }|j                  }|j                  r	 t	        j
                  |d||       }|S t        | |fd      }|t        ur|S 	 t/        j0                  d| |      \  }}}}|dd }t3        j4                         r&d}	|j6                  }
t3        j8                  d|
|	|       |\  }|S # t        j                  $ r }t        j                  ||       Y d}~nd}~wt        j                  $ r Y nw xY w	 t        | |fd      }|t        ur|S t        | ||      S # t        j                  $ r Y t        t         f$ rH t#        j$                  t&        dt)        | |            }|t"        j*                  j,                  ur|cY S  w xY w# t        t         f$ rH t#        j$                  t&        dt)        | |            }|t"        j*                  j,                  ur|cY S  w xY w)zComputes fingerprints of the input strings.

  Args:
    input: A `Tensor` of type `string`.
      vector of strings to compute fingerprints on.
    name: A name for the operation (optional).

  Returns:
    A `Tensor` of type `int64`.
  
SdcaFprintN)namectx )r   r   )_contextr   _thread_local_datais_eagerr   TFE_Py_FastPathExecute_core_NotOkStatusException_opsraise_from_not_ok_status_FallbackException_dispatcher_for_sdca_fprintNotImplementedsdca_fprint_eager_fallback_SymbolicException	TypeError
ValueError	_dispatchr   sdca_fprintdictOpDispatcherNOT_SUPPORTED_op_def_library_apply_op_helper_executemust_record_gradientinputsrecord_gradient)r   r   _ctxtld_resulte__op_outputs_attrs_inputs_flats              R/home/dcms/DCMS/lib/python3.12/site-packages/tensorflow/python/ops/gen_sdca_ops.pyr+   r+      s	    
			0h..0$#\\11lD%)gn, *	Gn$n	
)::E.Aq#x QK'""$F::LlFG5('	.W && -
##At,,## 
+$.$ g		&'
d& &## 
z" ""TD9g 
	..<<	<  Z	  
  
r4e$7
G i,,:::n	
sP    C 3F4 D(DDD E 8E F1AF1/F14AH	Hzraw_ops.SdcaFprintc                     t        j                  | t        j                        } | g}d }t	        j
                  dd||||      }t	        j                         rt	        j                  d|||       |\  }|S )Ns
   SdcaFprint   r3   attrsr   r   r   )r!   convert_to_tensor_dtypesstringr1   r   r2   r4   )r   r   r   r=   r<   r7   s         r>   r&   r&   `   sp    

 
 
7%,&]Al#)s?'""$lFG5('	.    SdcaOptimizer)out_example_state_dataout_delta_sparse_weightsout_delta_dense_weightsztrain.sdca_optimizersparse_example_indicessparse_feature_indicessparse_feature_valuesdense_featuresexample_weightsexample_labelssparse_indicessparse_weightsdense_weightsexample_state_data	loss_typel1l2num_loss_partitionsnum_inner_iterations
adaptativec                    t         j                   xs t        j                         }|j                  }|j                  rE	 t	        j
                  |d|| |||||||||	d|
d|d|d|d|d|      }t        j                  |      }|S t        | |||||||||	|
||||||fd      }|t        ur|S t3        | t4        t6        f      st#        d| z        t9        |       }t3        |t4        t6        f      st#        d|z        t9        |      |k7  rt%        dt9        |      |fz        t3        |t4        t6        f      st#        d|z        t9        |      |k7  rt%        dt9        |      |fz        t3        |t4        t6        f      st#        d|z        t9        |      |k7  rt%        dt9        |      |fz        t3        |t4        t6        f      st#        d|z        t9        |      }t3        |t4        t6        f      st#        d|z        t9        |      }t3        |t4        t6        f      st#        d|z        t9        |      |k7  rt%        d t9        |      |fz        t;        j<                  |
d      }
t;        j>                  |d      }t;        j>                  |d      }t;        j@                  |d      }t;        j@                  |d      }|d!}t;        jB                  |d      }	 tE        jF                  	 d'i d| d|d|d|d|d|d|d|d|d|	d|
d|d|d|d|d|d|\  }}}}|dd }t;        jH                         rd|jK                  d      d|jM                  d      d"|jO                  d"      d#|jO                  d#      d$|jO                  d$      d|jK                  d      d|jK                  d      d|jO                  d      d|jO                  d      f}|jP                  }t;        jR                  d|||       |dd% |d%d%|z    gz   |d%|z   d z   }|dd& |d&d gz   }t        j                  |      }|S # t        j                  $ r }t        j                  ||       Y d}~nd}~wt        j                  $ r Y nw xY w	 t        | |||||||||	|
||||||fd      }|t        ur|S t        | |||||||||	|
|||||||	      S # t        j                   $ r Y Ft"        t$        f$ rw t'        j(                  t*        d
t-        d
i d| d|d|d|d|d|d|d|d|d|	d|
d|d|d|d|d|d|      }|t&        j.                  j0                  ur|cY S  w xY w# t"        t$        f$ rw t'        j(                  t*        d
t-        d
i d| d|d|d|d|d|d|d|d|d|	d|
d|d|d|d|d|d|      }|t&        j.                  j0                  ur|cY S  w xY w)(a  Distributed version of Stochastic Dual Coordinate Ascent (SDCA) optimizer for

  linear models with L1 + L2 regularization. As global optimization objective is
  strongly-convex, the optimizer optimizes the dual objective at each step. The
  optimizer applies each update one example at a time. Examples are sampled
  uniformly, and the optimizer is learning rate free and enjoys linear convergence
  rate.

  [Proximal Stochastic Dual Coordinate Ascent](http://arxiv.org/pdf/1211.2717v1.pdf).<br>
  Shai Shalev-Shwartz, Tong Zhang. 2012

  $$Loss Objective = \sum f_{i} (wx_{i}) + (l2 / 2) * |w|^2 + l1 * |w|$$

  [Adding vs. Averaging in Distributed Primal-Dual Optimization](http://arxiv.org/abs/1502.03508).<br>
  Chenxin Ma, Virginia Smith, Martin Jaggi, Michael I. Jordan,
  Peter Richtarik, Martin Takac. 2015

  [Stochastic Dual Coordinate Ascent with Adaptive Probabilities](https://arxiv.org/abs/1502.08053).<br>
  Dominik Csiba, Zheng Qu, Peter Richtarik. 2015

  Args:
    sparse_example_indices: A list of `Tensor` objects with type `int64`.
      a list of vectors which contain example indices.
    sparse_feature_indices: A list with the same length as `sparse_example_indices` of `Tensor` objects with type `int64`.
      a list of vectors which contain feature indices.
    sparse_feature_values: A list of `Tensor` objects with type `float32`.
      a list of vectors which contains feature value
      associated with each feature group.
    dense_features: A list of `Tensor` objects with type `float32`.
      a list of matrices which contains the dense feature values.
    example_weights: A `Tensor` of type `float32`.
      a vector which contains the weight associated with each
      example.
    example_labels: A `Tensor` of type `float32`.
      a vector which contains the label/target associated with each
      example.
    sparse_indices: A list with the same length as `sparse_example_indices` of `Tensor` objects with type `int64`.
      a list of vectors where each value is the indices which has
      corresponding weights in sparse_weights. This field maybe omitted for the
      dense approach.
    sparse_weights: A list with the same length as `sparse_example_indices` of `Tensor` objects with type `float32`.
      a list of vectors where each value is the weight associated with
      a sparse feature group.
    dense_weights: A list with the same length as `dense_features` of `Tensor` objects with type `float32`.
      a list of vectors where the values are the weights associated
      with a dense feature group.
    example_state_data: A `Tensor` of type `float32`.
      a list of vectors containing the example state data.
    loss_type: A `string` from: `"logistic_loss", "squared_loss", "hinge_loss", "smooth_hinge_loss", "poisson_loss"`.
      Type of the primal loss. Currently SdcaSolver supports logistic,
      squared and hinge losses.
    l1: A `float`. Symmetric l1 regularization strength.
    l2: A `float`. Symmetric l2 regularization strength.
    num_loss_partitions: An `int` that is `>= 1`.
      Number of partitions of the global loss function.
    num_inner_iterations: An `int` that is `>= 1`.
      Number of iterations per mini-batch.
    adaptative: An optional `bool`. Defaults to `True`.
      Whether to use Adaptive SDCA for the inner loop.
    name: A name for the operation (optional).

  Returns:
    A tuple of `Tensor` objects (out_example_state_data, out_delta_sparse_weights, out_delta_dense_weights).

    out_example_state_data: A `Tensor` of type `float32`.
    out_delta_sparse_weights: A list with the same length as `sparse_example_indices` of `Tensor` objects with type `float32`.
    out_delta_dense_weights: A list with the same length as `dense_features` of `Tensor` objects with type `float32`.
  rG   rU   rZ   rV   rW   rX   rY   N)rU   rZ   rV   rW   rX   rY   r   r   r   rK   rL   rM   rN   rO   rP   rQ   rR   rS   rT   r   SExpected list for 'sparse_example_indices' argument to 'sdca_optimizer' Op, not %r.SExpected list for 'sparse_feature_indices' argument to 'sdca_optimizer' Op, not %r.List argument 'sparse_feature_indices' to 'sdca_optimizer' Op with length %d must match length %d of argument 'sparse_example_indices'.KExpected list for 'sparse_indices' argument to 'sdca_optimizer' Op, not %r.List argument 'sparse_indices' to 'sdca_optimizer' Op with length %d must match length %d of argument 'sparse_example_indices'.KExpected list for 'sparse_weights' argument to 'sdca_optimizer' Op, not %r.List argument 'sparse_weights' to 'sdca_optimizer' Op with length %d must match length %d of argument 'sparse_example_indices'.RExpected list for 'sparse_feature_values' argument to 'sdca_optimizer' Op, not %r.KExpected list for 'dense_features' argument to 'sdca_optimizer' Op, not %r.JExpected list for 'dense_weights' argument to 'sdca_optimizer' Op, not %r.vList argument 'dense_weights' to 'sdca_optimizer' Op with length %d must match length %d of argument 'dense_features'.Tnum_sparse_featuresnum_sparse_features_with_valuesnum_dense_featuresr@      )rG   )*r   r   r   r   r   r   _SdcaOptimizerOutput_maker   r    r!   r"   r#   _dispatcher_for_sdca_optimizerr%   sdca_optimizer_eager_fallbackr'   r(   r)   r*   r   sdca_optimizerr,   r-   r.   
isinstancelisttuplelenr1   make_str
make_floatmake_int	make_boolr/   r0   r2   get_attr_get_attr_bool_get_attr_intr3   r4   )rK   rL   rM   rN   rO   rP   rQ   rR   rS   rT   rU   rV   rW   rX   rY   rZ   r   r5   r6   r7   r8   _attr_num_sparse_features%_attr_num_sparse_features_with_values_attr_num_dense_featuresr9   r:   r;   r<   r=   s                                r>   ro   ro   q   s   R 
			0h..0$#\\11ot%; 5~);	j$D"6K35IKg %**73gnX -	!7~Ir2/Bj$		1 378G n$n	*T5M	:
	')?	@A A ""89	*T5M	:
	')?	@A A 		 $==
	E	#	$&?@	AB B 
NT5M	2
	')7	89 9 	55
	E	^	78	9: : 
NT5M	2
	')7	89 9 	55
	E	^	78	9: : 
)D%=	9
	')>	?@ @ +..C*D'	NT5M	2
	')7	89 9 !0	MD%=	1
	')6	78 8 	33
	=	]	56	78 8 	;7)2t$"2t$" ))*=?TU!**+?AWXJ!!*l;*#
)::;0F;0F; 0E; )7	;
 *9; )7; )7; )7; (5; -?; $-; 24; 9;; .A; /C; %/; 6:;Aq#xF QK'""$3<<4l  .0E 56/ AB"C$5$56J$KCLL&cll4.@#S%6%67L%M$ 67	9F ::Lvw8BQK71Q)B%BCDDwqSlOlOmGnn'BQK712;-'' &&w/'	.K && -
##At,,## 
%.!#9

..-
iR1D

D	3 59:g 
	&*
 "8

..-
	jB,?3$DJ J ## 
z" ""B !G<R !G<R!G;P!G 5C!G 6E	!G
 5C!G 5C!G 5C!G 4A!G 9K!G 09!G >@!G EG!G :M!G ;O!G 1;!G BF!Gg  
	..<<	<'R Z	  
  
"d E:P E:PE9NE 3AE 4C	E
 3AE 3AE 3AE 2?E 7IE .7E <>E CEE 8KE 9ME /9E @DE
G  i,,:::n	'
sR    AQ -AU9 RQ::RR&S >S U61BU64U69BW?=W?zraw_ops.SdcaOptimizerc                 D	   t        | t        t        f      st        d| z        t	        |       }t        |t        t        f      st        d|z        t	        |      |k7  rt        dt	        |      |fz        t        |t        t        f      st        d|z        t	        |      |k7  rt        dt	        |      |fz        t        |t        t        f      st        d|z        t	        |      |k7  rt        dt	        |      |fz        t        |t        t        f      st        d|z        t	        |      }t        |t        t        f      st        d	|z        t	        |      }t        |t        t        f      st        d
|z        t	        |      |k7  rt        dt	        |      |fz        t        j                  |
d      }
t        j                  |d      }t        j                  |d      }t        j                  |d      }t        j                  |d      }|d}t        j                  |d      }t        j                  | t        j                        } t        j                  |t        j                        }t        j                  |t        j                        }t        j                  |t        j                        }t        j                   |t        j                        }t        j                   |t        j                        }t        j                  |t        j                        }t        j                  |t        j                        }t        j                  |t        j                        }t        j                   |	t        j                        }	t        |       t        |      z   t        |      z   t        |      z   ||gz   t        |      z   t        |      z   t        |      z   |	gz   }d|
d|d|d|d|d|d|d|d|f}t        j"                  d||z   dz   ||||      }t        j$                         rt        j&                  d|||       |d d |dd|z    gz   |d|z   d  z   }|d d |dd  gz   }t(        j+                  |      }|S )Nr\   r]   r^   r_   r`   ra   rb   rc   rd   re   rf   rU   rV   rW   rX   rY   TrZ   rg   rh   ri   s   SdcaOptimizerr@   rA   rG   rj   )rp   rq   rr   r(   rs   r)   r1   rt   ru   rv   rw   r!   convert_n_to_tensorrD   int64float32rC   r   r2   r4   rk   rl   )rK   rL   rM   rN   rO   rP   rQ   rR   rS   rT   rU   rV   rW   rX   rY   rZ   r   r   r{   r|   r}   r=   r<   r7   s                           r>   rn   rn   r  s8   	*T5M	:
	')?	@A A ""89	*T5M	:
	')?	@A A 		 $==
	E	#	$&?@	AB B 
NT5M	2
	')7	89 9 	55
	E	^	78	9: : 
NT5M	2
	')7	89 9 	55
	E	^	78	9: : 
)D%=	9
	')>	?@ @ +..C*D'	NT5M	2
	')7	89 9 !0	MD%=	1
	')6	78 8 	33
	=	]	56	78 8 	;7)2t$"2t$" ))*=?TU!**+?AWXJ!!*l;*334JGMMZ334JGMMZ223H'//Z++NGOOL.**?GOOL/)).'//J.++NGMMJ.++NGOOL.**='//J---.@'//R,-5K0LLtTiOjjmq  sA  nB  B  FU  We  Ef  f  im  n|  i}  }  @D  ES  @T  T  W[  \i  Wj  j  n@  mA  A,L*2#%J0$D",.D& -/H506890:$0C"&(' ""$vw8BQK71Q)B%BCDDwqSlOlOmGnn'BQK712;-'' &&w/'	.rF   SdcaOptimizerV2adaptivec                 L	   t         j                   xs t        j                         }|j                  }|j                  rE	 t	        j
                  |d|| |||||||||	d|
d|d|d|d|d|      }t        j                  |      }|S t        | t         t"        f      st%        d
| z        t'        |       }t        |t         t"        f      st%        d|z        t'        |      |k7  rt)        dt'        |      |fz        t        |t         t"        f      st%        d|z        t'        |      |k7  rt)        dt'        |      |fz        t        |t         t"        f      st%        d|z        t'        |      |k7  rt)        dt'        |      |fz        t        |t         t"        f      st%        d|z        t'        |      }t        |t         t"        f      st%        d|z        t'        |      }t        |t         t"        f      st%        d|z        t'        |      |k7  rt)        dt'        |      |fz        t+        j,                  |
d      }
t+        j.                  |d      }t+        j.                  |d      }t+        j0                  |d      }t+        j0                  |d      }|d}t+        j2                  |d      }t5        j6                  	 d&i d| d|d|d|d|d|d|d|d|d|	d|
d|d|d|d|d|d |\  }}}}|dd }t+        j8                         rd|j;                  d      d|j=                  d      d!|j?                  d!      d"|j?                  d"      d#|j?                  d#      d|j;                  d      d|j;                  d      d|j?                  d      d|j?                  d      f}|j@                  }t+        jB                  d|||       |dd$ |d$d$|z    gz   |d$|z   d z   }|dd% |d%d gz   }t        j                  |      }|S # t        j                  $ r }t        j                  ||       Y d}~nd}~wt        j                  $ r Y nw xY w	 t        | |||||||||	|
|||||||	      S # t        j                  $ r Y w xY w)'a  Distributed version of Stochastic Dual Coordinate Ascent (SDCA) optimizer for

  linear models with L1 + L2 regularization. As global optimization objective is
  strongly-convex, the optimizer optimizes the dual objective at each step. The
  optimizer applies each update one example at a time. Examples are sampled
  uniformly, and the optimizer is learning rate free and enjoys linear convergence
  rate.

  [Proximal Stochastic Dual Coordinate Ascent](http://arxiv.org/pdf/1211.2717v1.pdf).<br>
  Shai Shalev-Shwartz, Tong Zhang. 2012

  $$Loss Objective = \sum f_{i} (wx_{i}) + (l2 / 2) * |w|^2 + l1 * |w|$$

  [Adding vs. Averaging in Distributed Primal-Dual Optimization](http://arxiv.org/abs/1502.03508).<br>
  Chenxin Ma, Virginia Smith, Martin Jaggi, Michael I. Jordan,
  Peter Richtarik, Martin Takac. 2015

  [Stochastic Dual Coordinate Ascent with Adaptive Probabilities](https://arxiv.org/abs/1502.08053).<br>
  Dominik Csiba, Zheng Qu, Peter Richtarik. 2015

  Args:
    sparse_example_indices: A list of `Tensor` objects with type `int64`.
      a list of vectors which contain example indices.
    sparse_feature_indices: A list with the same length as `sparse_example_indices` of `Tensor` objects with type `int64`.
      a list of vectors which contain feature indices.
    sparse_feature_values: A list of `Tensor` objects with type `float32`.
      a list of vectors which contains feature value
      associated with each feature group.
    dense_features: A list of `Tensor` objects with type `float32`.
      a list of matrices which contains the dense feature values.
    example_weights: A `Tensor` of type `float32`.
      a vector which contains the weight associated with each
      example.
    example_labels: A `Tensor` of type `float32`.
      a vector which contains the label/target associated with each
      example.
    sparse_indices: A list with the same length as `sparse_example_indices` of `Tensor` objects with type `int64`.
      a list of vectors where each value is the indices which has
      corresponding weights in sparse_weights. This field maybe omitted for the
      dense approach.
    sparse_weights: A list with the same length as `sparse_example_indices` of `Tensor` objects with type `float32`.
      a list of vectors where each value is the weight associated with
      a sparse feature group.
    dense_weights: A list with the same length as `dense_features` of `Tensor` objects with type `float32`.
      a list of vectors where the values are the weights associated
      with a dense feature group.
    example_state_data: A `Tensor` of type `float32`.
      a list of vectors containing the example state data.
    loss_type: A `string` from: `"logistic_loss", "squared_loss", "hinge_loss", "smooth_hinge_loss", "poisson_loss"`.
      Type of the primal loss. Currently SdcaSolver supports logistic,
      squared and hinge losses.
    l1: A `float`. Symmetric l1 regularization strength.
    l2: A `float`. Symmetric l2 regularization strength.
    num_loss_partitions: An `int` that is `>= 1`.
      Number of partitions of the global loss function.
    num_inner_iterations: An `int` that is `>= 1`.
      Number of iterations per mini-batch.
    adaptive: An optional `bool`. Defaults to `True`.
      Whether to use Adaptive SDCA for the inner loop.
    name: A name for the operation (optional).

  Returns:
    A tuple of `Tensor` objects (out_example_state_data, out_delta_sparse_weights, out_delta_dense_weights).

    out_example_state_data: A `Tensor` of type `float32`.
    out_delta_sparse_weights: A list with the same length as `sparse_example_indices` of `Tensor` objects with type `float32`.
    out_delta_dense_weights: A list with the same length as `dense_features` of `Tensor` objects with type `float32`.
  r   rU   r   rV   rW   rX   rY   N)rU   r   rV   rW   rX   rY   r   r   VExpected list for 'sparse_example_indices' argument to 'sdca_optimizer_v2' Op, not %r.VExpected list for 'sparse_feature_indices' argument to 'sdca_optimizer_v2' Op, not %r.List argument 'sparse_feature_indices' to 'sdca_optimizer_v2' Op with length %d must match length %d of argument 'sparse_example_indices'.NExpected list for 'sparse_indices' argument to 'sdca_optimizer_v2' Op, not %r.List argument 'sparse_indices' to 'sdca_optimizer_v2' Op with length %d must match length %d of argument 'sparse_example_indices'.NExpected list for 'sparse_weights' argument to 'sdca_optimizer_v2' Op, not %r.List argument 'sparse_weights' to 'sdca_optimizer_v2' Op with length %d must match length %d of argument 'sparse_example_indices'.UExpected list for 'sparse_feature_values' argument to 'sdca_optimizer_v2' Op, not %r.NExpected list for 'dense_features' argument to 'sdca_optimizer_v2' Op, not %r.MExpected list for 'dense_weights' argument to 'sdca_optimizer_v2' Op, not %r.yList argument 'dense_weights' to 'sdca_optimizer_v2' Op with length %d must match length %d of argument 'dense_features'.TrK   rL   rM   rN   rO   rP   rQ   rR   rS   rT   r   rg   rh   ri   r@   rj   )r   )"r   r   r   r   r   r   _SdcaOptimizerV2Outputrl   r   r    r!   r"   r#    sdca_optimizer_v2_eager_fallbackr'   rp   rq   rr   r(   rs   r)   r1   rt   ru   rv   rw   r/   r0   r2   rx   ry   rz   r3   r4   )rK   rL   rM   rN   rO   rP   rQ   rR   rS   rT   rU   rV   rW   rX   rY   r   r   r5   r6   r7   r8   r{   r|   r}   r9   r:   r;   r<   r=   s                                r>   sdca_optimizer_v2r     s   J 
			0h..0$#\\11'= 5~);	:$D"&;35IKg ',,W5gn  
*T5M	:
	*,B	CD D ""89	*T5M	:
	*,B	CD D 		 $==
	E	#	$&?@	AB B 
NT5M	2
	*,:	;< < 	55
	E	^	78	9: : 
NT5M	2
	*,:	;< < 	55
	E	^	78	9: : 
)D%=	9
	*,A	BC C +..C*D'	NT5M	2
	*,:	;< < !0	MD%=	1
	*,9	:; ; 	33
	=	]	56	78 8 	;7)2t$"2t$" ))*=?TU!**+?AWXH*5('8892H92H9 2G9 +9	9
 ,;9 +99 +99 +99 *79 /A9 &/9 469 ;=9 0C9 1E9 %-9 489!QX QK'""$3<<4j  ,.C 56/ AB"C$5$56J$KCLL&cll4.@#S%6%67L%M$ 67	9F ::L<:BQK71Q)B%BCDDwqSlOlOmGnn'BQK712;-''"((1'	.W && -
##At,,## 
	-
 "8

..-
	H%83$DJ J ## 
s1    AP$ $Q+7QQ+*Q+/R R#"R#zraw_ops.SdcaOptimizerV2c                 D	   t        | t        t        f      st        d| z        t	        |       }t        |t        t        f      st        d|z        t	        |      |k7  rt        dt	        |      |fz        t        |t        t        f      st        d|z        t	        |      |k7  rt        dt	        |      |fz        t        |t        t        f      st        d|z        t	        |      |k7  rt        dt	        |      |fz        t        |t        t        f      st        d|z        t	        |      }t        |t        t        f      st        d	|z        t	        |      }t        |t        t        f      st        d
|z        t	        |      |k7  rt        dt	        |      |fz        t        j                  |
d      }
t        j                  |d      }t        j                  |d      }t        j                  |d      }t        j                  |d      }|d}t        j                  |d      }t        j                  | t        j                        } t        j                  |t        j                        }t        j                  |t        j                        }t        j                  |t        j                        }t        j                   |t        j                        }t        j                   |t        j                        }t        j                  |t        j                        }t        j                  |t        j                        }t        j                  |t        j                        }t        j                   |	t        j                        }	t        |       t        |      z   t        |      z   t        |      z   ||gz   t        |      z   t        |      z   t        |      z   |	gz   }d|
d|d|d|d|d|d|d|d|f}t        j"                  d||z   dz   ||||      }t        j$                         rt        j&                  d|||       |d d |dd|z    gz   |d|z   d  z   }|d d |dd  gz   }t(        j+                  |      }|S )Nr   r   r   r   r   r   r   r   r   r   r   rU   rV   rW   rX   rY   Tr   rg   rh   ri   s   SdcaOptimizerV2r@   rA   r   rj   )rp   rq   rr   r(   rs   r)   r1   rt   ru   rv   rw   r!   r   rD   r   r   rC   r   r2   r4   r   rl   )rK   rL   rM   rN   rO   rP   rQ   rR   rS   rT   rU   rV   rW   rX   rY   r   r   r   r{   r|   r}   r=   r<   r7   s                           r>   r   r     s9   	*T5M	:
	*,B	CD D ""89	*T5M	:
	*,B	CD D 		 $==
	E	#	$&?@	AB B 
NT5M	2
	*,:	;< < 	55
	E	^	78	9: : 
NT5M	2
	*,:	;< < 	55
	E	^	78	9: : 
)D%=	9
	*,A	BC C +..C*D'	NT5M	2
	*,:	;< < !0	MD%=	1
	*,9	:; ; 	33
	=	]	56	78 8 	;7)2t$"2t$" ))*=?TU!**+?AWXH*5(334JGMMZ334JGMMZ223H'//Z++NGOOL.**?GOOL/)).'//J.++NGMMJ.++NGOOL.**='//J---.@'//R,-5K0LLtTiOjjmq  sA  nB  B  FU  We  Ef  f  im  n|  i}  }  @D  ES  @T  T  W[  \i  Wj  j  n@  mA  A,J2#%J0$D",.D& /1J526892:$0C"&(' ""$<:BQK71Q)B%BCDDwqSlOlOmGnn'BQK712;-''"((1'	.rF   ztrain.sdca_shrink_l1weightsc                 z   t         j                   xs t        j                         }|j                  }|j                  rt	        d      t        | |||fd      }|t        ur|S t        | t        t        f      st        d| z        t        |       }t        j                  |d      }t        j                  |d      }	 t        j                  d| |||      \  }}}	}
|	S # t        t         f$ rJ t#        j$                  t&        dt)        | |||            }|t"        j*                  j,                  ur|cY S  w xY w)	a  Applies L1 regularization shrink step on the parameters.

  Args:
    weights: A list of `Tensor` objects with type mutable `float32`.
      a list of vectors where each value is the weight associated with a
      feature group.
    l1: A `float`. Symmetric l1 regularization strength.
    l2: A `float`.
      Symmetric l2 regularization strength. Should be a positive float.
    name: A name for the operation (optional).

  Returns:
    The created Operation.
  Ksdca_shrink_l1 op does not support eager execution. Arg 'weights' is a ref.NzDExpected list for 'weights' argument to 'sdca_shrink_l1' Op, not %r.rV   rW   SdcaShrinkL1)r   rV   rW   r   r   )r   r   r   r   RuntimeError_dispatcher_for_sdca_shrink_l1r%   rp   rq   rr   r(   rs   r1   ru   r/   r0   r)   r*   r   sdca_shrink_l1r,   r-   r.   )r   rV   rW   r   r5   r6   r7   _attr_num_featuresr9   r:   r;   s              r>   r   r     s?   & 
			0h..0$#\\
d
ee,	"b$ $(Gn$n	GdE]	+
	')0	12 2 7|2t$"2t$"	
)::B2DBAq#x 
* Z	  
  
"d7rbtL
G i,,:::n	
s    C! !AD:8D:zraw_ops.SdcaShrinkL1c                     t        d      )Nr   )r   )r   rV   rW   r   r   s        r>   sdca_shrink_l1_eager_fallbackr     s    bccrF   )N)TN)B__doc__collectionstensorflow.pythonr   tensorflow.python.eagerr   r   r   r   r   r1   tensorflow.python.frameworkr   rD   tensorflow.security.fuzzing.pyr   _atypesr	   _op_def_registryr
   r!   r   r/   "tensorflow.python.util.deprecationr   tensorflow.python.utilr   r*    tensorflow.python.util.tf_exportr   typingr   r   r   typing_extensionsr   add_fallback_dispatch_listadd_type_based_api_dispatcherStringInt64r+   	to_raw_opr   _tf_type_based_dispatcherDispatchr$   r&   
namedtuplerk   Float32strfloatintboolro   rG   rm   rn   r   r   r   r   r   r   r   r   r   rF   r>   <module>r      s^  
  6 7 1 7 9 F K 3 I C 8 6 % % '
%%
((
"#$)*=ygnn!45 =YsT[TaTaOaEb = + % ) &=~ -Y+,^T^^K-HI
)CCLL 
iW^^0C&D 
T]^acjcpcp^pTq 
 .{--UW 
 %%
((
%&',-w9T#Y5M+N whqrvwzr{  ~E  ~K  ~K  sK  iL w  en  os  tw  ox  zA  zI  zI  oI  eJ w  \e  fj  kn  fo  qx  q@  q@  f@  \A w  T]  ^a  cj  cr  cr  ^r  Ts w  EN  OR  T[  Tc  Tc  Oc  Ed w  v  @D  EH  @I  KR  KX  KX  @X  vY w  kt  uy  z}  u~  @G  @O  @O  uO  kP w  aj  ko  ps  kt  v}  vE  vE  kE  aF w  \e  fi  kr  kz  kz  fz  \{ w  H	K	 w  Q	V	 w  \	a	 w  x	{	 w  S
V
 w  c
g
 w . ( ) &wr 3	12>4>>.3QR!/!I!I!R!R W)DIw}}D\:] W  xA  BF  GJ  BK  MT  MZ  MZ  BZ  x[ W  t}  ~B  CF  ~G  IP  IX  IX  ~X  tY W  kt  uy  z}  u~  @G  @O  @O  uO  kP W  cl  mp  ry  rA  rA  mA  cB W  T]  ^a  cj  cr  cr  ^r  Ts W  EN  OS  TW  OX  Za  Zg  Zg  Og  Eh W  zC  DH  IL  DM  OV  O^  O^  D^  z_ W  py  z~  B  zC  EL  ET  ET  zT  pU W  kt  ux  zA	  zI	  zI	  uI	  kJ	 W  W	Z	 W  `	e	 W  k	p	 W  G
J
 W  b
e
 W  s
w
 Wr 0//UW 
}iS	7==8P.Q }ktuyz}u~  AH  AN  AN  vN  lO }  hq  rv  wz  r{  }D  }L  }L  rL  hM }  _h  im  nq  ir  t{  tC  tC  iC  _D }  W`  ad  fm  fu  fu  au  Wv }  HQ  RU  W^  Wf  Wf  Rf  Hg }  yB  CG  HK  CL  NU  N[  N[  C[  y\ }  nw  x|  }@  xA  CJ  CR  CR  xR  nS }  dm  nr  sv  nw  y@  yH  yH  nH  dI }  _h  il  nu  n}  n}  i}  _~ }  K	N	 }  T	Y	 }  _	d	 }  {	~	 }  V
Y
 }  d
h
 }~ 7)56~t~~FW7XYWYtCyRYR_R_G_=` W  {D  EI  JM  EN  PW  P]  P]  E]  {^ W  w@  AE  FI  AJ  LS  L[  L[  A[  w\ W  nw  x|  }@  xA  CJ  CR  CR  xR  nS W  fo  ps  u|  uD  uD  pD  fE W  W`  ad  fm  fu  fu  au  Wv W  HQ  RV  WZ  R[  ]d  ]j  ]j  Rj  Hk W  }F  GK  LO  GP  RY  Ra  Ra  Ga  }b W  s|  }A  BE  }F  HO  HW  HW  }W  sX W  nw  x{  }D	  }L	  }L	  xL	  nM	 W  Z	]	 W  c	h	 W  n	s	 W  J
M
 W  e
h
 W  t
x
 Wt %%
((
%&',-*Id3i&@A *u *RW * . ( ) &*V 1y/01OP!/!I!I!R!R d9T#Y5O+P dV[ daf drF   