
    2Vh]i                         d dl Z d dlZd dlZd dl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  e
d
       G d de             ZddZy)    N)backend)ops)tree)keras_export)Callback)	Embedding)	Optimizer)
file_utilszkeras.callbacks.TensorBoardc                       e Zd ZdZ	 	 	 	 	 	 	 	 	 d! fd	Zd Zed        Zed        Zed        Z	d Z
d Zd	 Zd
 Zd Zd Zd Zd"dZd"dZd"dZd"dZd"dZd"dZd"dZd"dZd"dZd Zd"dZd Zd Zd Zd Zd Z d Z!d Z"d#d Z# xZ$S )$TensorBoarda  Enable visualizations for TensorBoard.

    TensorBoard is a visualization tool provided with TensorFlow. A TensorFlow
    installation is required to use this callback.

    This callback logs events for TensorBoard, including:

    * Metrics summary plots
    * Training graph visualization
    * Weight histograms
    * Sampled profiling

    When used in `model.evaluate()` or regular validation
    in addition to epoch summaries, there will be a summary that records
    evaluation metrics vs `model.optimizer.iterations` written. The metric names
    will be prepended with `evaluation`, with `model.optimizer.iterations` being
    the step in the visualized TensorBoard.

    If you have installed TensorFlow with pip, you should be able
    to launch TensorBoard from the command line:

    ```
    tensorboard --logdir=path_to_your_logs
    ```

    You can find more information about TensorBoard
    [here](https://www.tensorflow.org/get_started/summaries_and_tensorboard).

    Args:
        log_dir: the path of the directory where to save the log files to be
            parsed by TensorBoard. e.g.,
            `log_dir = os.path.join(working_dir, 'logs')`.
            This directory should not be reused by any other callbacks.
        histogram_freq: frequency (in epochs) at which to compute
            weight histograms for the layers of the model. If set to 0,
            histograms won't be computed. Validation data (or split) must be
            specified for histogram visualizations.
        write_graph:  (Not supported at this time)
            Whether to visualize the graph in TensorBoard.
            Note that the log file can become quite large
            when `write_graph` is set to `True`.
        write_images: whether to write model weights to visualize as image in
            TensorBoard.
        write_steps_per_second: whether to log the training steps per second
            into TensorBoard. This supports both epoch and batch frequency
            logging.
        update_freq: `"batch"` or `"epoch"` or integer. When using `"epoch"`,
            writes the losses and metrics to TensorBoard after every epoch.
            If using an integer, let's say `1000`, all metrics and losses
            (including custom ones added by `Model.compile`) will be logged to
            TensorBoard every 1000 batches. `"batch"` is a synonym for 1,
            meaning that they will be written every batch.
            Note however that writing too frequently to TensorBoard can slow
            down your training, especially when used with distribution
            strategies as it will incur additional synchronization overhead.
            Batch-level summary writing is also available via `train_step`
            override. Please see
            [TensorBoard Scalars tutorial](
                https://www.tensorflow.org/tensorboard/scalars_and_keras#batch-level_logging)
            for more details.
        profile_batch: Profile the batch(es) to sample compute characteristics.
            profile_batch must be a non-negative integer or a tuple of integers.
            A pair of positive integers signify a range of batches to profile.
            By default, profiling is disabled.
        embeddings_freq: frequency (in epochs) at which embedding layers will be
            visualized. If set to 0, embeddings won't be visualized.
        embeddings_metadata: Dictionary which maps embedding layer names to the
            filename of a file in which to save metadata for the embedding layer.
            In case the same metadata file is to be
            used for all embedding layers, a single filename can be passed.

    Examples:

    ```python
    tensorboard_callback = keras.callbacks.TensorBoard(log_dir="./logs")
    model.fit(x_train, y_train, epochs=2, callbacks=[tensorboard_callback])
    # Then run the tensorboard command to view the visualizations.
    ```

    Custom batch-level summaries in a subclassed Model:

    ```python
    class MyModel(keras.Model):

        def build(self, _):
            self.dense = keras.layers.Dense(10)

        def call(self, x):
            outputs = self.dense(x)
            tf.summary.histogram('outputs', outputs)
            return outputs

    model = MyModel()
    model.compile('sgd', 'mse')

    # Make sure to set `update_freq=N` to log a batch-level summary every N
    # batches.  In addition to any `tf.summary` contained in `model.call()`,
    # metrics added in `Model.compile` will be logged every N batches.
    tb_callback = keras.callbacks.TensorBoard('./logs', update_freq=1)
    model.fit(x_train, y_train, callbacks=[tb_callback])
    ```

    Custom batch-level summaries in a Functional API Model:

    ```python
    def my_summary(x):
        tf.summary.histogram('x', x)
        return x

    inputs = keras.Input(10)
    x = keras.layers.Dense(10)(inputs)
    outputs = keras.layers.Lambda(my_summary)(x)
    model = keras.Model(inputs, outputs)
    model.compile('sgd', 'mse')

    # Make sure to set `update_freq=N` to log a batch-level summary every N
    # batches. In addition to any `tf.summary` contained in `Model.call`,
    # metrics added in `Model.compile` will be logged every N batches.
    tb_callback = keras.callbacks.TensorBoard('./logs', update_freq=1)
    model.fit(x_train, y_train, callbacks=[tb_callback])
    ```

    Profiling:

    ```python
    # Profile a single batch, e.g. the 5th batch.
    tensorboard_callback = keras.callbacks.TensorBoard(
        log_dir='./logs', profile_batch=5)
    model.fit(x_train, y_train, epochs=2, callbacks=[tensorboard_callback])

    # Profile a range of batches, e.g. from 10 to 20.
    tensorboard_callback = keras.callbacks.TensorBoard(
        log_dir='./logs', profile_batch=(10,20))
    model.fit(x_train, y_train, epochs=2, callbacks=[tensorboard_callback])
    ```
    c
                 p   t         
|           t        |      | _        || _        || _        || _        || _        |dk(  rdn|| _        || _	        |	| _
        |rt        j                         dvr$t        dt        j                          d| d      t        j                         dk(  rCt        j                  d   dk  r-t        j                   d	t        j                          d
       d}| j#                  |       d| _        d| _        d| _        d| _        d| _        d | _        i | _        g | _        y )Nbatch   )jax
tensorflowz(Profiling is not yet available with the zV backend. Please open a PR if you'd like to add this feature. Received: profile_batch=z (must be 0)r      zProfiling with the z! backend requires python >= 3.12.r   )super__init__strlog_dirhistogram_freqwrite_graphwrite_imageswrite_steps_per_secondupdate_freqembeddings_freqembeddings_metadatar   
ValueErrorsysversion_infowarningswarn_init_profile_batch_global_train_batch_global_test_batch_previous_epoch_iterations_train_accumulated_time_batch_start_time_summary_module_writers_prev_summary_state)selfr   r   r   r   r   r   profile_batchr   r   	__class__s             O/home/dcms/DCMS/lib/python3.12/site-packages/keras/src/callbacks/tensorboard.pyr   zTensorBoard.__init__   s?    	7|,&(&<# +w 61K.#6  (== >() *%%2O<A  "e+##A&+MM-"??,--NP %&M  /#$ "#*+''($!"#  $&     c                    || _         | j                  | _        t        j                  j                  | j                  d      | _        t        j                  j                  | j                  d      | _        i | _        d| _	        | j                  r| j                          d| _	        | j                  r| j                          yy)z/Sets Keras model and writes graph if specified.train
validationFTN)_modelr   _log_write_dirospathjoin
_train_dir_val_dirr*   _should_write_train_graphr   _write_keras_model_summaryr   _configure_embeddings)r,   models     r/   	set_modelzTensorBoard.set_model   s    "ll'',,t':':GDT%8%8,G).&++--1D*&&(  r0   c                 L    | j                   dd lm} || _         | j                   S Nr   )r)   tensorflow.summarysummary)r,   rC   s     r/   rC   zTensorBoard.summary   s%    '0#*D ###r0   c                     d| j                   vr2| j                  j                  | j                        | j                   d<   | j                   d   S )Nr2   )r*   rC   create_file_writerr9   r,   s    r/   _train_writerzTensorBoard._train_writer   sC    $--'%)\\%D%D&DMM'" }}W%%r0   c                     d| j                   vr2| j                  j                  | j                        | j                   d<   | j                   d   S )Nval)r*   rC   rE   r:   rF   s    r/   _val_writerzTensorBoard._val_writer   sC    %#'<<#B#B$DMM%  }}U##r0   c                 |   | j                   j                         5  | j                  j                  }t	        |d      rkt	        |d      r0| j
                  j                  |j                  j                         n/| j
                  j                  |j                  j                         ddd       y# 1 sw Y   yxY w)z7Writes Keras model train_function graph to TensorBoard.function_spec_concrete_stateful_fnN)	rG   
as_defaultr>   train_functionhasattrrC   graphrM   _concrete_variable_creation_fn)r,   train_fns     r/   _write_keras_model_train_graphz*TensorBoard._write_keras_model_train_graph   s    **, 	zz00H x18%<=LL&&x'E'E'K'KLLL&& ??EE	 	 	s   BB22B;c                    | j                   j                         5  | j                  j                  j                  dk(  s#| j                  j                  j                  dk(  rt        d| j                  d       ddd       y# 1 sw Y   yxY w)z2Writes Keras graph network summary to TensorBoard.
Functional
Sequentialkerasr   stepN)rG   rN   r>   r.   __name__keras_model_summaryrF   s    r/   r<   z&TensorBoard._write_keras_model_summary	  sm    **, 	A

$$--=::''00L@#GTZZa@	A 	A 	As   ABBc                 t   ddl m} ddlm} |j	                         }| j
                  j                  D ]  }t        |t              s|j                  j                         }d}||_        | j                  Dt        | j                  t              r| j                  |_        p|j                  | j                  j!                         v s| j                  j#                  |j                        |_         | j                  r@t        | j                  t              s&t%        d| j                  j!                                |j'                  |      }t(        j*                  j-                  | j.                  d      }t1        j2                  |d      5 }	|	j5                  |       ddd       y# 1 sw Y   yxY w)	z'Configure the Projector for embeddings.r   )text_format)	projectorz:layer_with_weights-0/embeddings/.ATTRIBUTES/VARIABLE_VALUENzmUnrecognized `Embedding` layer names passed to `keras.callbacks.TensorBoard` `embeddings_metadata` argument: zprojector_config.pbtxtw)google.protobufr^   tensorboard.pluginsr_   ProjectorConfigr>   layers
isinstancer   
embeddingsaddtensor_namer   r   metadata_pathnamekeyspopr   MessageToStringr6   r7   r8   r5   r
   Filewrite)
r,   r^   r_   configlayer	embeddingrj   config_pbtxtr7   fs
             r/   r=   z!TensorBoard._configure_embeddings  sp   /1**,ZZ&& 	E%+"--113	 Q  )-	%++7!$":":C@262J2J	/ ::)A)A)F)F)HH $ 8 8 < <UZZ H &3	& ##J$$c-
 !55::<=?  #226:ww||D//1IJ__T3' 	"1GGL!	" 	" 	"s   F..F7c                      j                   dk(  ry fd}|j                         j                  j                  |      f} j                  j                  |       |d   j                          |d   j                          y)z9Sets the default writer for custom batch-level summaries.epochNc                  (     j                   z  dk(  S rA   )r   )r,   rZ   s   r/   should_recordz/TensorBoard._push_writer.<locals>.should_record>  s    $***a//r0   r   r   )r   rN   rC   	record_ifr+   append	__enter__)r,   writerrZ   rx   summary_contexts   ` `  r/   _push_writerzTensorBoard._push_writer9  sz    w&	0 d#LL""=1
 	  ''8$$&$$&r0   c                     | j                   dk(  ry| j                  j                         } |d   j                  t	        j
                            |d   j                  t	        j
                           y)zPops the current writer.rv   Nr   r   )r   r+   rl   __exit__r   exc_info)r,   previous_contexts     r/   _pop_writerzTensorBoard._pop_writerI  sb    w&  33779$$$clln5$$$clln5r0   c                 b    | j                   j                         D ]  }|j                           y N)r*   valuesclose)r,   r|   s     r/   _close_writerszTensorBoard._close_writersT  s'    mm**, 	FLLN	r0   c                    d| }t        |t              r4t        |      j                  d      }t        j                  t
        |      }t        |t
              r|| _        || _        n?t        |t        t        f      rt        |      dk(  r|\  | _        | _        nt        |      | j                  dk  s| j                  | j                  k  rt        |      d| _        d| _        | j                  dkD  r$| j                  d       | j                  d	       d| _        | j                  dk(  xr | j                  dk(   | _        y)
a  Validate profile_batch value and set the range of batches to profile.

        Sets values of _start_batch and _stop_batch attributes,
        specifying the start and stop batch to profile.
        Setting `profile_batch=0` disables profiling.

        Args:
          profile_batch: The range of batches to profile. Should be a
            non-negative integer or a comma separated string of pair of positive
            integers. A pair of positive integers signify a range of batches to
            profile.

        Raises:
          ValueError: If profile_batch is not an integer or a comma separated
            pair of positive integers.

        zprofile_batch must be a non-negative integer or 2-tuple of positive integers. A pair of positive integers signifies a range of batches to profile. Found: ,   r   FN logdirsave)re   r   splitr   map_structureint_start_batch_stop_batchtuplelistlenr   _profiler_started_batch_trace_context_start_profiler_stop_profiler_is_tracing_should_trace)r,   r-   profile_batch_error_messages      r/   r#   zTensorBoard._init_profile_batchX  s<   &" #0	2 	$ mS).44S9M ..sMBMmS) -D,D}udm4]9Kq9P2?/Dt/899q D$4$4t7H7H$H899
 "'$(!q    +U+  "<t'7'71'<
r0   c                 l    d| _         d| _        | j                  | j                  | j                          y rA   )r$   r&   r~   rG   r,   logss     r/   on_train_beginzTensorBoard.on_train_begin  s.    #$ *+'$,,d.F.FGr0   c                 |    | j                          | j                  r| j                          | j                          y r   )r   r   _stop_tracer   r   s     r/   on_train_endzTensorBoard.on_train_end  s/    r0   c                 P    | j                  | j                  | j                         y r   )r~   rJ   r%   r   s     r/   on_test_beginzTensorBoard.on_test_begin  s    $**D,C,CDr0   c                    | j                   j                  rt        | j                   j                  d      r~| j                  j	                         5  |j                         D ]G  \  }}| j                  j                  d|z   dz   || j                   j                  j                         I 	 d d d        | j                          y # 1 sw Y   xY w)N
iterationsevaluation__vs_iterationsrY   )
r>   	optimizerrP   rJ   rN   itemsrC   scalarr   r   )r,   r   rj   values       r/   on_test_endzTensorBoard.on_test_end  s    ::GDJJ,@,@,$O!!,,. #'::< KD%LL''%,/??!ZZ11<< (  	 s   ACCc                 F   | xj                   dz  c_         | j                  rt        j                         | _        | j                  sy | j                   | j
                  k(  r| j                          | j                  r%t        j                  j                  |      | _        y y Nr   )r$   r   timer(   r   r   _start_tracer   r   tensorboardstart_batch_tracer   r,   r   r   s      r/   on_train_batch_beginz TensorBoard.on_train_batch_begin  s      A% &&%)YY[D"!!##t'8'88!!(/(;(;(M(M)D% "r0   c                    | j                   r| j                          d| _         | j                  rLt        j                         | j                  z
  }| j
                  j                  dd|z  | j                         t        |t              rC|j                         D ]0  \  }}| j
                  j                  d|z   || j                         2 | j                  sy | j                  rs| j                  r<| j                  0t        j                   j#                  | j                         d | _        | j                  | j$                  k\  r| j'                          y y y )NFbatch_steps_per_secondg      ?rY   batch_)r;   rT   r   r   r(   rC   r   r$   re   dictr   r   r   r   r   r   r   stop_batch_tracer   r   )r,   r   r   batch_run_timerj   r   s         r/   on_train_batch_endzTensorBoard.on_train_batch_end  s-   ))//1-2D*&&!YY[4+A+AANLL(n$--    dD!#zz| e##tOU1I1I $ 
 !!%%$*C*C*O##44T5N5NO,0)''4+;+;;  " <	 r0   c                 .    | xj                   dz  c_         y r   )r%   r   s      r/   on_test_batch_beginzTensorBoard.on_test_batch_begin  s    1$r0   c                     | j                   rSt        j                  | j                  j                  j
                  d      | _        t        j                         | _        y y Nfloat32)	r   r   convert_to_tensorr>   r   r   r&   r   _epoch_start_timer,   rv   r   s      r/   on_epoch_beginzTensorBoard.on_epoch_begin  sH    &&.1.C.C

$$///D+ &*YY[D"	 'r0   c                     | j                  ||       | j                  r#|| j                  z  dk(  r| j                  |       | j                  r%|| j                  z  dk(  r| j	                  |       yyy)z2Runs metrics and histogram summaries at epoch end.r   N)_log_epoch_metricsr   _log_weightsr   _log_embeddingsr   s      r/   on_epoch_endzTensorBoard.on_epoch_end  sm    t,54+>+>#>!#Ce$ED,@,@$@A$E  ' %Fr0   c                     | j                   j                  dd       | j                  | j                         d| _        y )NTF)rQ   profilerr   )rC   trace_onr   r9   r   rF   s    r/   r   zTensorBoard._start_trace  s6    D59DOO4r0   c                     || j                   }| j                  j                         5  | j                  j	                  d|z  |       ddd       | j                          d| _        y# 1 sw Y   !xY w)z$Logs the trace graph to TensorBoard.Nzbatch_%d)rj   rZ   F)r   rG   rN   rC   trace_exportr   r   )r,   r   s     r/   r   zTensorBoard._stop_trace  so    =$$E**, 	KLL%%:+=E%J	K 	 		K 	Ks   !A**A3c                     t        | j                  j                  t              r?t	        t        j                  | j                  j                  j                              |d<   |S )Nlearning_rate)re   r>   r   r	   floatr   convert_to_numpyr   r   s     r/   _collect_learning_ratez"TensorBoard._collect_learning_rate   sJ    djj**I6$)$$TZZ%9%9%G%GH%D! r0   c                    | j                   j                  j                  }t        j                         | j                  z
  }t        j                  |d      }t        j                  |d      }|| j                  z
  |z  }t        |      S r   )	r>   r   r   r   r   r   r   r&   r   )r,   current_iterationtime_since_epoch_beginsteps_per_seconds       r/   _compute_steps_per_secondz%TensorBoard._compute_steps_per_second  s     JJ00;;!%t/E/E!E112CYO!$!6!6"I"

  ? ??"# %&&r0   c                    |sy|j                         D ci c]  \  }}|j                  d      r|| }}}|j                         D ci c]  \  }}|j                  d      s|| }}}| j                  |      }| j                  r| j	                         |d<   |r]| j
                  j                         5  |j                         D ]&  \  }}| j                  j                  d|z   ||       ( 	 ddd       |rc| j                  j                         5  |j                         D ]+  \  }}|dd }| j                  j                  d|z   ||       - 	 ddd       yyc c}}w c c}}w # 1 sw Y   {xY w# 1 sw Y   yxY w)zWrites epoch metrics out as scalar summaries.

        Args:
            epoch: Int. The global step to use for TensorBoard.
            logs: Dict. Keys are scalar summary names, values are scalars.
        Nval_r   epoch_rY      )
r   
startswithr   r   r   rG   rN   rC   r   rJ   )	r,   rv   r   kv
train_logsval_logsrj   r   s	            r/   r   zTensorBoard._log_epoch_metrics  s    '+zz|Ptq!1<<;OadP
P%)ZZ\JTQQ\\&5IAqDJJ00<
&&-1-K-K-MJ)*##..0 L#-#3#3#5 LKD%LL''4U'KLL !!,,. L#+>>#3 LKD%8DLL''4U'KLL L  QJL LL Ls.   E#E#E)&E)::E/?E;/E8;Fc                    | j                   j                         5  | j                  j                  D ]w  }|j                  D ]f  }|j
                  j                  dd      }|dz   }| j                  j                  |||       | j                  sO|dz   }| j                  |||       h y | j                   j                          ddd       y# 1 sw Y   yxY w)z-Logs the weights of the Model to TensorBoard.:_z
/histogramrY   z/imageN)rG   rN   r>   rd   weightsrj   replacerC   	histogramr   _log_weight_as_imageflush)r,   rv   rq   weightweight_namehistogram_weight_nameimage_weight_names          r/   r   zTensorBoard._log_weights.  s    **, 	'** #mm F"(++"5"5c3"?K,7,,F)LL**-vE +  (( -8(,B)11"$5u $$&!	' 	' 	's   A4C6CCc                    t        j                  |      }|j                  }t        |      dk(  rt        j                  |d|d   ddg      }nt        |      dk(  rM|d   |d   kD  r!t        j
                  |      }|j                  }t        j                  |d|d   |d   dg      }nlt        |      dk(  r^t        j                         dk(  r$t        j
                  |g d      }|j                  }t        j                  ||d   |d   |d   dg      }t        j                  |      }|j                  }t        |      dk(  r'|d   d	v r| j                  j                  |||
       yyy)z%Logs a weight as a TensorBoard image.r   r   r      channels_last)r   r   r   r   )r   r   r   rY   N)r   squeezeshaper   reshape	transposer   image_data_formatr   rC   image)r,   r   r   rv   w_imgr   s         r/   r   z TensorBoard._log_weight_as_imageB  s?   F#u:?KK58Q':;EZ1_Qx%("e,KK58U1Xq'ABEZ1_((*o= eY7KKa%(E!Ha'HIE((/u:?uRyI5LL{E>  6?r0   c                     t         j                  j                  | j                  dd| d      }| j                  j                  |       y )Nr2   zkeras_embedding.ckpt-z.weights.h5)r6   r7   r8   r5   r>   save_weights)r,   rv   embeddings_ckpts      r/   r   zTensorBoard._log_embeddings[  s@    '',,#E7+6

 	

0r0   c                     | j                   ry	 t        j                  j                  |       d| _         y# t        $ r }t        j                  d|       Y d}~yd}~ww xY w)zStarts the profiler if currently inactive.

        Args:
          logdir: Directory where profiler results will be saved.
        NTzFailed to start profiler: %s)r   r   r   start_trace	Exceptionloggingerror)r,   r   es      r/   r   zTensorBoard._start_profilerc  sS     !!	=++F3%)D" 	=MM8!<<	=s   &6 	AAAc                     | j                   sy	 t        j                  j                  |       d| _         y# t        $ r }t        j                  d|       Y d}~,d}~ww xY w# d| _         w xY w)zStops the profiler if currently active.

        Args:
          save: Whether to save the profiler results to TensorBoard.
        Nr   zFailed to stop profiler: %sF)r   r   r   
stop_tracer  r  r  )r,   r   r  s      r/   r   zTensorBoard._stop_profilerr  se     %%	+***5
 &+D"	  	<MM7;;	< &+D"s'    7 	A  AA# A  A# #	A,)	r   r   TFFrv   r   r   Nr   )T)%r[   
__module____qualname____doc__r   r?   propertyrC   rG   rJ   rT   r<   r=   r~   r   r   r#   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   __classcell__)r.   s   @r/   r   r      s    GV $ 4&l)  $ $ & & $ $A%"N' 	6<
|H
E	#:%1( 
!'L4'(?21=+r0   r   c                    ddl m} ddlm}  |       }d|j                  _        d|j                  _        	 |j                         }|j                  j                  | d||g      5 \  }}	|j                  ||||      cddd       S # t        $ r"}t        j                  d|        Y d}~yd}~ww xY w# 1 sw Y   yxY w)	a  Writes a Keras model as JSON to as a Summary.

    Writing the Keras model configuration allows the TensorBoard graph plugin to
    render a conceptual graph, as opposed to graph of ops. In case the model
    fails to serialize as JSON, it ignores and returns False.

    Args:
        name: A name for this summary. The summary tag used for TensorBoard will
            be this name prefixed by any active name scopes.
        data: A Keras Model to write.
        step: Explicit `int64`-castable monotonic step value for this summary.
            If omitted, this defaults to `tf.summary.experimental.get_step()`,
            which must not be `None`.

    Returns:
        True on success, or False if no summary was written because no default
        summary writer was available.

    Raises:
        ValueError: if a default writer exists, but no step was provided and
            `tf.summary.experimental.get_step()` is `None`.
    r   N)SummaryMetadatagraph_keras_model   1z/Model failed to serialize as JSON. Ignoring... F)tagtensorrZ   metadata)rB   rC   tensorflow.compat.v1r  plugin_dataplugin_namecontentto_jsonr  r!   r"   experimentalsummary_scopero   )
rj   datarZ   rC   r  summary_metadatajson_stringexcr  r   s
             r/   r\   r\     s    . )4&( 0C  ,+/  (lln 
			+	+!D$<
 
	#q}}Kd=M  

 
  GuMN

 
s#   B &B6	B3B..B36B?r   )r  r6   r   r   r!   	keras.srcr   r   r   keras.src.api_exportr   keras.src.callbacks.callbackr   keras.src.layersr   keras.src.optimizersr	   keras.src.utilsr
   r   r\    r0   r/   <module>r'     sV     	 
      - 1 & * & +,n	+( n	+ -n	+b-
r0   