From 3743a890661fbae619f9b168610fcccd7b11a134 Mon Sep 17 00:00:00 2001 From: Dong Shin Date: Wed, 27 Jul 2022 03:12:24 +0900 Subject: [PATCH] Add OPT Model --- oslo/transformers/mapping_utils.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/oslo/transformers/mapping_utils.py b/oslo/transformers/mapping_utils.py index 48093289..83fd3727 100644 --- a/oslo/transformers/mapping_utils.py +++ b/oslo/transformers/mapping_utils.py @@ -125,6 +125,12 @@ class _TensorParallelMappingForHuggingFace(_ParallelMappingForHuggingFace): Update("embed_dim", "num_attention_heads"), Head("lm_head", "score"), ], + OPT=[ + Column("q_proj", "k_proj", "v_proj", "fc1"), + Row("out_proj", "fc2"), + Update("embed_dim", "num_heads"), + Head("lm_head", "score"), + ], "Electra": [ Column("query", "key", "value", "intermediate.dense"), Column(