diff options
Diffstat (limited to 'training/conf/criterion')
-rw-r--r-- | training/conf/criterion/mae.yaml | 2 | ||||
-rw-r--r-- | training/conf/criterion/vqgan_loss.yaml | 12 |
2 files changed, 14 insertions, 0 deletions
diff --git a/training/conf/criterion/mae.yaml b/training/conf/criterion/mae.yaml new file mode 100644 index 0000000..cb07467 --- /dev/null +++ b/training/conf/criterion/mae.yaml @@ -0,0 +1,2 @@ +_target_: torch.nn.L1Loss +reduction: mean diff --git a/training/conf/criterion/vqgan_loss.yaml b/training/conf/criterion/vqgan_loss.yaml new file mode 100644 index 0000000..a1c886e --- /dev/null +++ b/training/conf/criterion/vqgan_loss.yaml @@ -0,0 +1,12 @@ +_target_: text_recognizer.criterions.vqgan_loss.VQGANLoss +reconstruction_loss: + _target_: torch.nn.L1Loss + reduction: mean +discriminator: + _target_: text_recognizer.criterions.n_layer_discriminator.NLayerDiscriminator + in_channels: 1 + num_channels: 32 + num_layers: 3 +vq_loss_weight: 1.0 +discriminator_weight: 1.0 + |