rphrp1985 commited on
Commit
129a84f
1 Parent(s): 07f3caf

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -108,8 +108,8 @@ def respond(
108
  input_str= str(input_ids2)
109
  print('input str = ', input_str)
110
 
111
-
112
- gen_tokens = model.generate(
113
  input_ids,
114
  max_new_tokens=max_tokens,
115
  # do_sample=True,
 
108
  input_str= str(input_ids2)
109
  print('input str = ', input_str)
110
 
111
+ with torch.no_grad():
112
+ gen_tokens = model.generate(
113
  input_ids,
114
  max_new_tokens=max_tokens,
115
  # do_sample=True,