You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
"Special tokens have been added in the vocabulary, make sure the associated word embeddings are fine-tuned or trained.\n"
23
-
]
24
-
},
25
-
{
26
-
"name": "stdout",
27
-
"output_type": "stream",
28
-
"text": [
29
-
"Creating DFA mask store for CodeGenTokenizerFast and json, may take more than 10 minutes. Caching at /home/shubham/syncode/cache/mask_stores/CodeGenTokenizerFast/grammar_strict_1003218229_50257.pkl.\n",
"/home/shubham/anaconda3/envs/codex/lib/python3.11/site-packages/tqdm/auto.py:21: TqdmWarning: IProgress not found. Please update jupyter and ipywidgets. See https://ipywidgets.readthedocs.io/en/stable/user_install.html\n",
13
+
" from .autonotebook import tqdm as notebook_tqdm\n"
ifself.oppand (gen_mode==GenerationMode.SAMPLEorgen_mode==GenerationMode.GREEDY_SEARCH)andbatch_size==1: # Use our own implementation for greedy search and sampling
96
+
ifself.oppand (gen_mode==GenerationMode.SAMPLEorgen_mode==GenerationMode.GREEDY_SEARCH): # Use our own implementation for greedy search and sampling
97
97
generated_ids=self._generate(
98
98
inputs,
99
99
gen_config,
100
100
gen_mode,
101
101
grammar_decoder=self.grammar_decoder,
102
-
stop_criteria=stop_criteria
102
+
stopping_criteria=stop_criteria
103
103
)
104
104
else:
105
105
ifself.opp:
@@ -137,20 +137,19 @@ def _generate(
137
137
gen_config:GenerationConfig,
138
138
gen_mode:GenerationMode,
139
139
grammar_decoder:SyncodeLogitsProcessor=None,
140
-
stop_criteria:StoppingCriteria=[]
140
+
stopping_criteria:StoppingCriteria=[]
141
141
):
142
142
"""
143
143
We support greedy search and sampling for batch size 1 otherwise we use the generate function from transformers library.
0 commit comments