vinayakdev commited on
Commit
e899f04
1 Parent(s): c782bf6

add progress

Browse files
Files changed (1) hide show
  1. generator.py +5 -0
generator.py CHANGED
@@ -115,9 +115,14 @@ def create_string_for_generator(context):
115
  def creator(context):
116
  questions = create_string_for_generator(context)
117
  pairs = []
 
 
 
118
  for ques in questions:
 
119
  pair = QA(ques,context)
120
  pairs.append(pair)
 
121
  return pairs
122
 
123
  # sentences = main_text.split('.')
 
115
  def creator(context):
116
  questions = create_string_for_generator(context)
117
  pairs = []
118
+ l = len(questions)
119
+ x = 100/l
120
+ i=0
121
  for ques in questions:
122
+ st.progress(i)
123
  pair = QA(ques,context)
124
  pairs.append(pair)
125
+ i = i + x
126
  return pairs
127
 
128
  # sentences = main_text.split('.')