vaniagrawal commited on
Commit
9468aa0
·
verified ·
1 Parent(s): 59b2b3f

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -12,7 +12,7 @@ tokenizer = AutoTokenizer.from_pretrained(model_name, token=hf_token)
12
 
13
 
14
  def generate_code(prompt):
15
- batch_size = 1
16
  inputs = tokenizer(input_texts, return_tensors="pt", padding=True, truncation=True, max_length=512)
17
  outputs = model.generate(inputs['input_ids'], max_length=512, num_return_sequences=batch_size)
18
  code = tokenizer.decode(outputs[0], skip_special_tokens=True)
 
12
 
13
 
14
  def generate_code(prompt):
15
+ batch_size = 10
16
  inputs = tokenizer(input_texts, return_tensors="pt", padding=True, truncation=True, max_length=512)
17
  outputs = model.generate(inputs['input_ids'], max_length=512, num_return_sequences=batch_size)
18
  code = tokenizer.decode(outputs[0], skip_special_tokens=True)