
    6bi                     X    S r SSKJr  SSKJr  SSKJr  \" S5       " S S\5      5       rg)	z*Contains the ActivityRegularization layer.    )regularizers)Layer)keras_exportz#keras.layers.ActivityRegularizationc                   B   ^  \ rS rSrSrSU 4S jjrS rU 4S jrSrU =r	$ )ActivityRegularization   a  Layer that applies an update to the cost function based input activity.

Args:
  l1: L1 regularization factor (positive float).
  l2: L2 regularization factor (positive float).

Input shape:
  Arbitrary. Use the keyword argument `input_shape`
  (tuple of integers, does not include the samples axis)
  when using this layer as the first layer in a model.

Output shape:
  Same shape as input.
c           	      t   > [         TU ]  " SS[        R                  " XS90UD6  SU l        Xl        X l        g )Nactivity_regularizerl1l2T )super__init__r   L1L2supports_maskingr   r   )selfr   r   kwargs	__class__s       t/home/james-whalen/.local/lib/python3.13/site-packages/tf_keras/src/layers/regularization/activity_regularization.pyr   ActivityRegularization.__init__*   s?     	
!-!2!2b!@	
DJ	
 !%    c                     U$ )Nr   )r   input_shapes     r   compute_output_shape+ActivityRegularization.compute_output_shape2   s    r   c                    > U R                   U R                  S.n[        TU ]  5       n[	        [        UR                  5       5      [        UR                  5       5      -   5      $ )Nr   )r   r   r   
get_configdictlistitems)r   configbase_configr   s      r   r   !ActivityRegularization.get_config5   sK    tww/g(*D**,-V\\^0DDEEr   )r   r   r   )        r%   )
__name__
__module____qualname____firstlineno____doc__r   r   r   __static_attributes____classcell__)r   s   @r   r   r      s    F Fr   r   N)r*   tf_keras.srcr   tf_keras.src.engine.base_layerr    tensorflow.python.util.tf_exportr   r   r   r   r   <module>r0      s;    1 & 0 : 34FU F 5Fr   