Skip to content

Config fix#39

Open
agoryuno wants to merge 4 commits into
microsoft:mainfrom
agoryuno:config-fix
Open

Config fix#39
agoryuno wants to merge 4 commits into
microsoft:mainfrom
agoryuno:config-fix

Conversation

@agoryuno

@agoryuno agoryuno commented Jul 10, 2023

Copy link
Copy Markdown

I've rewritten the torchscale.architecture.config module to use inheritance and remove the redundant code. There are now 3 classes:

Config - that holds all common options
EncoderConfig - inherits 'Config' and holds Encoder specific options
DecoderConfig - inherits 'Config' and holds Decoder specific options
EncoderDecoderConfig - inherits EncoderConfig and DecoderConfig and holds that one option shared by Encoder and Decoder objects.

I also took the liberty to add some type hints for args parameters in encoder/decoder modules.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

1 participant