Skip to content

Only train on Decoder variables? #8

@tiancheng2000

Description

@tiancheng2000

Hi, I'm trying to migrate this sample to TL2.
But I found in train.py : 116 that optimizer only works for Decoder's variables, and there are codes restoring weights from .npz file to Encoders before training (and these weights will not be changed during training).
In order to migrate to TL2, and without pretrained Encoder's weights at hand, I need to write a model composed of 3 Encoders and 1 Decoders, and then config a tf.keras.optimizers.Adam optimizer to apply gradients to all trainable variables of the model, am i right?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions