Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
262 commits
Select commit Hold shift + click to select a range
276c8f4
commit
sfc-gh-zhwang Sep 17, 2023
d40b6a8
commit
sfc-gh-zhwang Sep 18, 2023
0286429
commit
sfc-gh-zhwang Sep 18, 2023
f450188
commit
sfc-gh-zhwang Sep 18, 2023
2365cdb
commit
sfc-gh-zhwang Sep 18, 2023
1543b00
commit
sfc-gh-zhwang Sep 18, 2023
a26793a
commit
sfc-gh-zhwang Sep 18, 2023
641e46d
commit
sfc-gh-zhwang Sep 18, 2023
e25ee28
commit
sfc-gh-zhwang Sep 18, 2023
bbca59f
commit
sfc-gh-zhwang Sep 18, 2023
f7f3f2e
commit
sfc-gh-zhwang Sep 18, 2023
1be58b7
commit
sfc-gh-zhwang Sep 18, 2023
3011aec
commit
sfc-gh-zhwang Sep 18, 2023
1b42159
commit
sfc-gh-zhwang Sep 18, 2023
53185a5
commit
sfc-gh-zhwang Sep 18, 2023
411892b
commit
sfc-gh-zhwang Sep 19, 2023
56bb47c
commit
sfc-gh-zhwang Sep 19, 2023
30f1642
commit
sfc-gh-zhwang Sep 19, 2023
1cc0eaf
commit
sfc-gh-zhwang Sep 19, 2023
ef97a9e
commit
sfc-gh-zhwang Sep 19, 2023
440de12
commit
sfc-gh-zhwang Sep 19, 2023
9d14482
commit
sfc-gh-zhwang Sep 19, 2023
f416d67
commit
sfc-gh-zhwang Sep 19, 2023
6b775c3
commit
sfc-gh-zhwang Sep 19, 2023
e665612
commit
sfc-gh-zhwang Sep 19, 2023
2490c02
commit
sfc-gh-zhwang Sep 19, 2023
6d126c2
commit
sfc-gh-zhwang Sep 19, 2023
bff97b1
commit
sfc-gh-zhwang Sep 19, 2023
a089a2f
commit
sfc-gh-zhwang Sep 19, 2023
ec035df
commit
sfc-gh-zhwang Sep 19, 2023
0e3fe4d
commit
sfc-gh-zhwang Sep 19, 2023
83668ea
commit
sfc-gh-zhwang Sep 19, 2023
432b3e4
commit
sfc-gh-zhwang Sep 19, 2023
67bc7a5
commit
sfc-gh-zhwang Sep 19, 2023
6405e97
commit
sfc-gh-zhwang Sep 19, 2023
9468a5a
commit
sfc-gh-zhwang Sep 19, 2023
b9f6b3b
commit
sfc-gh-zhwang Sep 19, 2023
5facbd0
commit
sfc-gh-zhwang Sep 19, 2023
4eb759b
commit
sfc-gh-zhwang Sep 19, 2023
7fadeba
commit
sfc-gh-zhwang Sep 20, 2023
889455e
commit
sfc-gh-zhwang Sep 20, 2023
2b2f3bd
commit
sfc-gh-zhwang Sep 20, 2023
b578e43
commit
sfc-gh-zhwang Sep 20, 2023
e391316
commit
sfc-gh-zhwang Sep 20, 2023
1cbca59
commit
sfc-gh-zhwang Sep 20, 2023
bbfd31e
commit
sfc-gh-zhwang Sep 20, 2023
de43b4d
commit
sfc-gh-zhwang Sep 20, 2023
cf6ae4f
commit
sfc-gh-zhwang Sep 20, 2023
ddc6e06
commit
sfc-gh-zhwang Sep 20, 2023
fe899c2
commit
sfc-gh-zhwang Sep 20, 2023
0c9668a
commit
sfc-gh-zhwang Sep 20, 2023
f1ea8ca
commit
sfc-gh-zhwang Sep 20, 2023
7dd957b
commit
sfc-gh-zhwang Sep 20, 2023
1a6cbea
commit
sfc-gh-zhwang Sep 20, 2023
820f68c
commit
sfc-gh-zhwang Sep 20, 2023
b84f60c
commit
sfc-gh-zhwang Sep 20, 2023
9b46552
commit
sfc-gh-zhwang Sep 20, 2023
2051da9
commit
sfc-gh-zhwang Sep 20, 2023
5ffda86
commit
sfc-gh-zhwang Sep 20, 2023
755fd9c
commit
sfc-gh-zhwang Sep 20, 2023
6abce2a
commit
sfc-gh-zhwang Sep 20, 2023
673c7ca
commit
sfc-gh-zhwang Sep 20, 2023
9a93d0a
commit
sfc-gh-zhwang Sep 20, 2023
db339ca
commit
sfc-gh-zhwang Sep 20, 2023
be63f1d
commit
sfc-gh-zhwang Sep 20, 2023
43b34b9
commit
sfc-gh-zhwang Sep 20, 2023
59ec3cf
commit
sfc-gh-zhwang Sep 20, 2023
3a17aaf
commit
sfc-gh-zhwang Sep 20, 2023
b884f27
commit
sfc-gh-zhwang Sep 20, 2023
e8b03a2
commit
sfc-gh-zhwang Sep 20, 2023
3afe0a6
commit
sfc-gh-zhwang Sep 20, 2023
42355a4
commit
sfc-gh-zhwang Sep 20, 2023
f7dfda2
commit
sfc-gh-zhwang Sep 20, 2023
db8ba08
commit
sfc-gh-zhwang Sep 20, 2023
d1d5f32
commit
sfc-gh-zhwang Sep 20, 2023
5223f3c
commit
sfc-gh-zhwang Sep 20, 2023
5b66179
commit
sfc-gh-zhwang Sep 20, 2023
108f295
commit
sfc-gh-zhwang Sep 20, 2023
becd868
commit
sfc-gh-zhwang Sep 20, 2023
1a40c51
commit
sfc-gh-zhwang Sep 20, 2023
ebf12e9
commit
sfc-gh-zhwang Sep 20, 2023
821e70f
commit
sfc-gh-zhwang Sep 20, 2023
8a54c97
commit
sfc-gh-zhwang Sep 20, 2023
a007343
commit
sfc-gh-zhwang Sep 20, 2023
3b3c162
commit
sfc-gh-zhwang Sep 20, 2023
3afbd0b
commit
sfc-gh-zhwang Sep 20, 2023
ae4b890
commit
sfc-gh-zhwang Sep 20, 2023
929f8bd
commit
sfc-gh-zhwang Sep 20, 2023
2678525
commit
sfc-gh-zhwang Sep 20, 2023
134bac2
commit
sfc-gh-zhwang Sep 20, 2023
ca81757
commit
sfc-gh-zhwang Sep 20, 2023
58adee1
commit
sfc-gh-zhwang Sep 20, 2023
7d2fdb6
commit
sfc-gh-zhwang Sep 20, 2023
a799fba
commit
sfc-gh-zhwang Sep 20, 2023
a5c1662
commit
sfc-gh-zhwang Sep 20, 2023
3c1b721
commit
sfc-gh-zhwang Sep 20, 2023
79600b2
commit
sfc-gh-zhwang Sep 20, 2023
922a295
commit
sfc-gh-zhwang Sep 20, 2023
4a2fb6a
commit
sfc-gh-zhwang Sep 20, 2023
e3bef9c
commit
sfc-gh-zhwang Sep 20, 2023
9f75a40
commit
sfc-gh-zhwang Sep 20, 2023
e6726ad
commit
sfc-gh-zhwang Sep 20, 2023
264e41c
commit
sfc-gh-zhwang Sep 20, 2023
94ecf8d
commit
sfc-gh-zhwang Sep 20, 2023
942d190
commit
sfc-gh-zhwang Sep 20, 2023
ccd18aa
commit
sfc-gh-zhwang Sep 20, 2023
9820254
commit
sfc-gh-zhwang Sep 20, 2023
bf3a61a
commit
sfc-gh-zhwang Sep 20, 2023
3a3e6af
commit
sfc-gh-zhwang Sep 20, 2023
ea27dd8
commit
sfc-gh-zhwang Sep 20, 2023
a5fc8ef
commit
sfc-gh-zhwang Sep 20, 2023
1db101c
commit
sfc-gh-zhwang Sep 20, 2023
6cc42df
commit
sfc-gh-zhwang Sep 20, 2023
ef0efb1
commit
sfc-gh-zhwang Sep 20, 2023
43896ae
commit
sfc-gh-zhwang Sep 20, 2023
afe6da8
commit
sfc-gh-zhwang Sep 20, 2023
7df4b83
commit
sfc-gh-zhwang Sep 20, 2023
50e76dd
commit
sfc-gh-zhwang Sep 20, 2023
7a70713
commit
sfc-gh-zhwang Sep 20, 2023
f69c2ff
commit
sfc-gh-zhwang Sep 20, 2023
1aa3334
commit
sfc-gh-zhwang Sep 20, 2023
92bcfd9
commit
sfc-gh-zhwang Sep 20, 2023
cc4efd0
commit
sfc-gh-zhwang Sep 20, 2023
03aa995
commit
sfc-gh-zhwang Sep 20, 2023
ae66ba0
commit
sfc-gh-zhwang Sep 20, 2023
321667c
commit
sfc-gh-zhwang Sep 20, 2023
e0cf38f
commit
sfc-gh-zhwang Sep 20, 2023
3f5db1e
commit
sfc-gh-zhwang Sep 20, 2023
9cf33f5
commit
sfc-gh-zhwang Sep 20, 2023
8583d77
commit
sfc-gh-zhwang Sep 20, 2023
2755984
commit
sfc-gh-zhwang Sep 21, 2023
f3bfdb9
commit
sfc-gh-zhwang Sep 21, 2023
c0fc6fa
commit
sfc-gh-zhwang Sep 21, 2023
9d9b899
commit
sfc-gh-zhwang Sep 21, 2023
e9ab268
commit
sfc-gh-zhwang Sep 21, 2023
c8b3c1f
commit
sfc-gh-zhwang Sep 21, 2023
af5e2d0
commit
sfc-gh-zhwang Sep 21, 2023
1290559
commit
sfc-gh-zhwang Sep 21, 2023
6ab81bb
commit
sfc-gh-zhwang Sep 21, 2023
f7d6181
commit
sfc-gh-zhwang Sep 21, 2023
c24d988
commit
sfc-gh-zhwang Sep 21, 2023
724f09f
commit
sfc-gh-zhwang Sep 21, 2023
1fb251f
commit
sfc-gh-zhwang Sep 21, 2023
03d9157
commit
sfc-gh-zhwang Sep 21, 2023
017b5f5
commit
sfc-gh-zhwang Sep 21, 2023
23ce1b8
commit
sfc-gh-zhwang Sep 21, 2023
7c52360
commit
sfc-gh-zhwang Sep 21, 2023
2bec74c
commit
sfc-gh-zhwang Sep 21, 2023
e28178d
commit
sfc-gh-zhwang Sep 21, 2023
ca44022
commit
sfc-gh-zhwang Sep 21, 2023
7932479
commit
sfc-gh-zhwang Sep 21, 2023
1be0d11
commit
sfc-gh-zhwang Sep 21, 2023
6796bd3
commit
sfc-gh-zhwang Sep 21, 2023
e838d99
commit
sfc-gh-zhwang Sep 21, 2023
f2176d9
commit
sfc-gh-zhwang Sep 21, 2023
660bc49
commit
sfc-gh-zhwang Sep 21, 2023
e2b06f9
commit
sfc-gh-zhwang Sep 21, 2023
f168f5a
commit
sfc-gh-zhwang Sep 21, 2023
b8022c7
commit
sfc-gh-zhwang Sep 21, 2023
0082ce6
commit
sfc-gh-zhwang Sep 21, 2023
89bca5d
commit
sfc-gh-zhwang Sep 21, 2023
30fc848
commit
sfc-gh-zhwang Sep 21, 2023
f26673a
commit
sfc-gh-zhwang Sep 21, 2023
fde7e7a
commit
sfc-gh-zhwang Sep 21, 2023
e6fa607
commit
sfc-gh-zhwang Sep 21, 2023
d2c9a9a
commit
sfc-gh-zhwang Sep 21, 2023
2642aae
commit
sfc-gh-zhwang Sep 21, 2023
b7a5685
commit
sfc-gh-zhwang Sep 21, 2023
f94c064
commit
sfc-gh-zhwang Sep 21, 2023
75f2e29
commit
sfc-gh-zhwang Sep 21, 2023
e934306
commit
sfc-gh-zhwang Sep 22, 2023
6006eae
commit
sfc-gh-zhwang Sep 22, 2023
bca15e7
commit
sfc-gh-zhwang Sep 22, 2023
041cd8e
commit
sfc-gh-zhwang Sep 22, 2023
52124fd
commit
sfc-gh-zhwang Sep 22, 2023
dce397f
commit
sfc-gh-zhwang Sep 22, 2023
e5836a6
commit
sfc-gh-zhwang Sep 22, 2023
63a1f61
commit
sfc-gh-zhwang Sep 22, 2023
46fb97d
commit
sfc-gh-zhwang Sep 22, 2023
84ca292
commit
sfc-gh-zhwang Sep 22, 2023
f3e0e34
commit
sfc-gh-zhwang Sep 22, 2023
ada0977
commit
sfc-gh-zhwang Sep 22, 2023
9d3947a
commit
sfc-gh-zhwang Sep 22, 2023
edc41c2
commit
sfc-gh-zhwang Sep 22, 2023
cec4eca
commit
sfc-gh-zhwang Sep 22, 2023
8e8e4af
commit
sfc-gh-zhwang Sep 22, 2023
235ef50
commit
sfc-gh-zhwang Sep 22, 2023
31f6f10
commit
sfc-gh-zhwang Sep 22, 2023
097f8c3
commit
sfc-gh-zhwang Sep 22, 2023
094d637
commit
sfc-gh-zhwang Sep 22, 2023
0d11a2f
commit
sfc-gh-zhwang Sep 22, 2023
6c0275a
commit
sfc-gh-zhwang Sep 22, 2023
f301442
commit
sfc-gh-zhwang Sep 22, 2023
c5786f7
commit
sfc-gh-zhwang Sep 22, 2023
ab8d796
commit
sfc-gh-zhwang Sep 22, 2023
be3b5a1
commit
sfc-gh-zhwang Sep 22, 2023
6841c8b
commit
sfc-gh-zhwang Sep 22, 2023
66333b1
commit
sfc-gh-zhwang Sep 22, 2023
573bdbc
commit
sfc-gh-zhwang Sep 22, 2023
c9baac9
commit
sfc-gh-zhwang Sep 22, 2023
285e55a
commit
sfc-gh-zhwang Sep 22, 2023
da0d7fa
commit
sfc-gh-zhwang Sep 22, 2023
04e2642
commit
sfc-gh-zhwang Sep 22, 2023
4698de7
commit
sfc-gh-zhwang Sep 22, 2023
94c31da
commit
sfc-gh-zhwang Sep 22, 2023
1699f14
commit
sfc-gh-zhwang Sep 22, 2023
d98c251
commit
sfc-gh-zhwang Sep 22, 2023
0bca9aa
commit
sfc-gh-zhwang Sep 22, 2023
ab5327c
commit
sfc-gh-zhwang Sep 22, 2023
cbd4958
commit
sfc-gh-zhwang Sep 22, 2023
23e97d4
commit
sfc-gh-zhwang Sep 22, 2023
8444e45
commit
sfc-gh-zhwang Sep 22, 2023
e331161
commit
sfc-gh-zhwang Sep 22, 2023
c86a384
commit
sfc-gh-zhwang Sep 22, 2023
2969057
commit
sfc-gh-zhwang Sep 22, 2023
7c26c1a
commit
sfc-gh-zhwang Sep 22, 2023
b222d50
commit
sfc-gh-zhwang Sep 22, 2023
cb5d936
commit
sfc-gh-zhwang Sep 22, 2023
52e3e3e
commit
sfc-gh-zhwang Sep 22, 2023
1a6ae8e
commit
sfc-gh-zhwang Sep 22, 2023
03cd96d
commit
sfc-gh-zhwang Sep 22, 2023
a5aac95
commit
sfc-gh-zhwang Sep 22, 2023
721e2b1
commit
sfc-gh-zhwang Sep 22, 2023
ef0994f
commit
sfc-gh-zhwang Sep 22, 2023
177935c
commit
sfc-gh-zhwang Sep 22, 2023
e4cfa3c
commit
sfc-gh-zhwang Sep 22, 2023
e14226e
commit
sfc-gh-zhwang Sep 22, 2023
5087376
commit
sfc-gh-zhwang Sep 22, 2023
b3491bf
commit
sfc-gh-zhwang Sep 22, 2023
d23cefe
commit
sfc-gh-zhwang Sep 22, 2023
a95aff4
commit
sfc-gh-zhwang Sep 22, 2023
53c4b28
commit
sfc-gh-zhwang Sep 22, 2023
82d1388
commit
sfc-gh-zhwang Sep 22, 2023
d056e3b
commit
sfc-gh-zhwang Sep 23, 2023
17af137
commit
sfc-gh-zhwang Sep 23, 2023
910169d
commit
sfc-gh-zhwang Sep 23, 2023
f06b30f
commit
sfc-gh-zhwang Sep 23, 2023
5996f5c
commit
sfc-gh-zhwang Sep 23, 2023
4a4a673
commit
sfc-gh-zhwang Sep 23, 2023
ef2b4aa
commit
sfc-gh-zhwang Sep 24, 2023
81f8437
commit
sfc-gh-zhwang Sep 24, 2023
0780913
commit
sfc-gh-zhwang Sep 24, 2023
ac96919
commit
sfc-gh-zhwang Sep 24, 2023
edfd4b9
commit
sfc-gh-zhwang Sep 24, 2023
cba8f48
commit
sfc-gh-zhwang Sep 24, 2023
ef1912d
commit
sfc-gh-zhwang Sep 24, 2023
c9911e1
commit
sfc-gh-zhwang Sep 24, 2023
2de726f
commit
sfc-gh-zhwang Sep 24, 2023
1790619
commit
sfc-gh-zhwang Sep 24, 2023
b997e17
commit
sfc-gh-zhwang Sep 24, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 19 additions & 2 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,23 @@
"unordered_set": "cpp",
"future": "cpp",
"cfenv": "cpp",
"typeindex": "cpp"
"typeindex": "cpp",
"__bit_reference": "cpp",
"__config": "cpp",
"__debug": "cpp",
"__errc": "cpp",
"__hash_table": "cpp",
"__locale": "cpp",
"__mutex_base": "cpp",
"__node_handle": "cpp",
"__split_buffer": "cpp",
"__threading_support": "cpp",
"__tree": "cpp",
"__verbose_abort": "cpp",
"charconv": "cpp",
"ios": "cpp",
"locale": "cpp",
"variant": "cpp",
"__memory": "cpp"
}
}
}
1 change: 1 addition & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -322,6 +322,7 @@ add_library(transformer-shared SHARED
$<TARGET_OBJECTS:BertLayerWeight>
$<TARGET_OBJECTS:BertTritonBackend>
$<TARGET_OBJECTS:BertWeight>
$<TARGET_OBJECTS:BartTritonBackend>
$<TARGET_OBJECTS:Deberta>
$<TARGET_OBJECTS:DebertaLayerWeight>
$<TARGET_OBJECTS:DebertaTritonBackend>
Expand Down
1 change: 1 addition & 0 deletions examples/cpp/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
# See the License for the specific language governing permissions and
# limitations under the License.

add_subdirectory(bart)
add_subdirectory(bert)
add_subdirectory(bert_int8)
add_subdirectory(decoding)
Expand Down
18 changes: 18 additions & 0 deletions examples/cpp/bart/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# Copyright (c) 2019-2023, NVIDIA CORPORATION. All rights reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

add_executable(bart_triton_example bart_triton_example.cc)
target_link_libraries(bart_triton_example PUBLIC -lcublas -lcublasLt -lcudart -lpthread
BartTritonBackend TransformerTritonBackend custom_ar_comm
gpt_example_utils word_list mpi_utils nccl_utils nvtx_utils)
2 changes: 2 additions & 0 deletions examples/cpp/bart/bad_words.csv
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
7768,3908
1,2
467 changes: 467 additions & 0 deletions examples/cpp/bart/bart_triton_example.cc

Large diffs are not rendered by default.

16 changes: 16 additions & 0 deletions examples/cpp/bart/check_with_huggingface.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
import transformers

from transformers import LlamaForCausalLM, LlamaTokenizer

tokenizer = LlamaTokenizer.from_pretrained('/data/llama-7b-hf')

prompt = "Hey, are you consciours? Can you talk to me?"
inputs = tokenizer(prompt, return_tensors='pt')
model = LlamaForCausalLM.from_pretrained("/data/llama-7b-hf")
hf_config = vars(model.config)
print(hf_config)
generated_ids = model.forward(inputs.input_ids, output_hidden_states=True)
print(generated_ids)

tokens = [0,18637,29892,526,366,1136,455,2470,29973,1815,366,5193,304,592,29973,18637,29892,526,366,1136,455,2470,29973,1815,366,5193,304,592,29973,18637,29892,526,366,1136,455,2470,29973,1815,366,5193,304,592,29973,18637,29892,526,366]
print(tokenizer.decode(tokens))
47 changes: 47 additions & 0 deletions examples/cpp/bart/config.ini
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
[ft_instance_hyperparameter]
data_type=fp16
enable_custom_all_reduce=0

tensor_para_size=1
pipeline_para_size=1

model_name=decoder
model_dir=/notebooks/bart-ft/1/1-gpu/

[request]
beam_width=1 # beam width for beam search
top_k=1 ; k value for top k sampling
top_p=0.0 ; p value for top p sampling
temperature=1.0 ; Use for sampling
repetition_penalty=1.0 ; Use for sampling
presence_penalty=0.0 ; Only one of repetition_penalty and presence_penalty are allowed.
len_penalty=0.0
beam_search_diversity_rate=0.0
request_batch_size=8 # determine by the request
request_output_len=32 # determine by the request

[encoder]
num_heads = 12
d_kv = 64
d_model = 768
d_ff = 3072
num_layers = 6
vocab_size = 50265
max_pos_seq_len = 1024
model_name = bart
feed_forward_proj = gelu
weight_data_type = fp32

[decoder]
num_heads = 12
d_kv = 64
d_model = 768
d_ff = 3072
num_layers = 6
vocab_size = 50265
max_pos_seq_len = 1024
decoder_start_token_id = 2
eos_token_id = 2
start_id = 1
end_id = 1
weight_data_type = fp32
2 changes: 2 additions & 0 deletions examples/cpp/bart/start_ids.csv
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
0, 4154, 1231, 15674, 345, 1534, 440, 50264, 11, 1854, 2
0, 4154, 1231, 15674, 345, 1534, 440, 50264, 11, 1854, 2
2 changes: 2 additions & 0 deletions examples/cpp/bart/stop_words.csv
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
287, 4346, 12
3, -1, -1
3 changes: 3 additions & 0 deletions examples/cpp/multi_gpu_gpt/gpt_example_utils.cc
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,9 @@ int read_start_ids(size_t batch_size,
v_start_lengths->push_back(tmp_start_lengths[i]);
}
}
for (int i : *v_start_lengths) {
printf("v_start_lengths %d\n", i);
}
return batch_size;
}

Expand Down
4 changes: 2 additions & 2 deletions examples/pytorch/bart/translate_example.py
Original file line number Diff line number Diff line change
Expand Up @@ -213,7 +213,7 @@ def translate(args_dict):
config.decoder_start_token_id, config.eos_token_id, config.vocab_size,
tensor_para_size=tensor_para_size, pipeline_para_size=pipeline_para_size,
bart_with_bias=bart_with_bias, mbart=is_mbart,
position_embedding_type=position_embedding_type,
position_embedding_type=position_embedding_type,
activation_type=activation_type, layernorm_type=layernorm_type)

ft_bart = FTBart(ft_encoder, ft_decoding)
Expand Down Expand Up @@ -375,4 +375,4 @@ def translate(args_dict):
args = parser.parse_args()
log_format = "%(asctime)s %(name)s [%(levelname)s] %(message)s"
logging.basicConfig(level=logging.DEBUG if args.verbose else logging.INFO, format=log_format)
translate(vars(args))
translate(vars(args))
Loading