File tree 1 file changed +2
-0
lines changed
1 file changed +2
-0
lines changed Original file line number Diff line number Diff line change @@ -90,6 +90,7 @@ def figure_out_max_prompt_length(
90
90
91
91
# Perform a binary search to find the max tokens between lower_bound and upper_bound
92
92
lower_bound += num_tokens_prefix + num_tokens_suffix
93
+ pbar : tqdm
93
94
with tqdm (total = int (math .log2 (upper_bound - lower_bound ))) as pbar :
94
95
while lower_bound < upper_bound :
95
96
middle = math .ceil ((lower_bound + upper_bound ) / 2 )
@@ -142,6 +143,7 @@ def figure_out_max_prompt_length_plus_tokens(
142
143
print ("The model has a limit on the number of tokens" )
143
144
144
145
# Perform a binary search to find the max tokens between lower_bound and upper_bound
146
+ pbar : tqdm
145
147
with tqdm (total = int (math .log2 (upper_bound - lower_bound ))) as pbar :
146
148
while lower_bound < upper_bound :
147
149
middle = math .ceil ((lower_bound + upper_bound ) / 2 )
You can’t perform that action at this time.
0 commit comments