Commit b067751 1 parent 9a0d589 commit b067751 Copy full SHA for b067751
File tree 1 file changed +4
-8
lines changed
aeon/clustering/deep_learning
1 file changed +4
-8
lines changed Original file line number Diff line number Diff line change @@ -367,20 +367,16 @@ def loss(y_true, y_pred):
367
367
if _name .startswith ("__act_decoder" ):
368
368
_decoder_intermediate_outputs .append (_prop )
369
369
370
- _encoder_intermediate_outputs = tf .stack (_encoder_intermediate_outputs )
371
- _decoder_intermediate_outputs = tf .stack (_decoder_intermediate_outputs )
372
-
373
370
if not (
374
371
len (_encoder_intermediate_outputs )
375
372
== len (_decoder_intermediate_outputs )
376
373
):
377
374
raise ValueError ("The Auto-Encoder must be symmetric in nature." )
378
375
379
- mse += K .mean (
380
- K .square (
381
- _encoder_intermediate_outputs - _decoder_intermediate_outputs
382
- )
383
- )
376
+ for enc_output , dec_output in zip (
377
+ _encoder_intermediate_outputs , _decoder_intermediate_outputs
378
+ ):
379
+ mse += K .mean (K .square (enc_output - dec_output ))
384
380
385
381
return mse
386
382
You can’t perform that action at this time.
0 commit comments