phenomenon1981 commited on
Commit
b68e8fb
1 Parent(s): 9dc4a13

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +9 -9
app.py CHANGED
@@ -43,7 +43,7 @@ def add_random_noise(prompt, noise_level=0.07):
43
  def send_it1(inputs, noise_level, proc1=proc1):
44
  prompt_with_noise = add_random_noise(inputs, noise_level)
45
  while queue.qsize() >= queue_threshold:
46
- time.sleep(1)
47
  queue.put(prompt_with_noise)
48
  output1 = proc1(queue.get())
49
  return output1
@@ -51,7 +51,7 @@ def send_it1(inputs, noise_level, proc1=proc1):
51
  def send_it2(inputs, noise_level, proc1=proc1):
52
  prompt_with_noise = add_random_noise(inputs, noise_level)
53
  while queue.qsize() >= queue_threshold:
54
- time.sleep(1)
55
  queue.put(prompt_with_noise)
56
  output2 = proc1(queue.get())
57
  return output2
@@ -59,7 +59,7 @@ def send_it2(inputs, noise_level, proc1=proc1):
59
  def send_it3(inputs, noise_level, proc1=proc1):
60
  prompt_with_noise = add_random_noise(inputs, noise_level)
61
  while queue.qsize() >= queue_threshold:
62
- time.sleep(1)
63
  queue.put(prompt_with_noise)
64
  output3 = proc1(queue.get())
65
  return output3
@@ -67,7 +67,7 @@ def send_it3(inputs, noise_level, proc1=proc1):
67
  def send_it4(inputs, noise_level, proc1=proc1):
68
  prompt_with_noise = add_random_noise(inputs, noise_level)
69
  while queue.qsize() >= queue_threshold:
70
- time.sleep(1)
71
  queue.put(prompt_with_noise)
72
  output4 = proc1(queue.get())
73
  return output4
@@ -75,7 +75,7 @@ def send_it4(inputs, noise_level, proc1=proc1):
75
  def send_it5(inputs, noise_level, proc1=proc1):
76
  prompt_with_noise = add_random_noise(inputs, noise_level)
77
  while queue.qsize() >= queue_threshold:
78
- time.sleep(1)
79
  queue.put(prompt_with_noise)
80
  output5 = proc1(queue.get())
81
  return output5
@@ -83,7 +83,7 @@ def send_it5(inputs, noise_level, proc1=proc1):
83
  def send_it6(inputs, noise_level, proc1=proc1):
84
  prompt_with_noise = add_random_noise(inputs, noise_level)
85
  while queue.qsize() >= queue_threshold:
86
- time.sleep(1)
87
  queue.put(prompt_with_noise)
88
  output6 = proc1(queue.get())
89
  return output6
@@ -91,7 +91,7 @@ def send_it6(inputs, noise_level, proc1=proc1):
91
  def send_it7(inputs, noise_level, proc1=proc1):
92
  prompt_with_noise = add_random_noise(inputs, noise_level)
93
  while queue.qsize() >= queue_threshold:
94
- time.sleep(1)
95
  queue.put(prompt_with_noise)
96
  output7 = proc1(queue.get())
97
  return output7
@@ -99,7 +99,7 @@ def send_it7(inputs, noise_level, proc1=proc1):
99
  def send_it8(inputs, noise_level, proc1=proc1):
100
  prompt_with_noise = add_random_noise(inputs, noise_level)
101
  while queue.qsize() >= queue_threshold:
102
- time.sleep(1)
103
  queue.put(prompt_with_noise)
104
  output8 = proc1(queue.get())
105
  return output8
@@ -107,7 +107,7 @@ def send_it8(inputs, noise_level, proc1=proc1):
107
 
108
  def get_prompts(prompt_text):
109
  while queue.qsize() >= queue_threshold:
110
- time.sleep(1)
111
  queue.put(prompt_text)
112
  output = text_gen(queue.get())
113
  return output
 
43
  def send_it1(inputs, noise_level, proc1=proc1):
44
  prompt_with_noise = add_random_noise(inputs, noise_level)
45
  while queue.qsize() >= queue_threshold:
46
+ time.sleep()
47
  queue.put(prompt_with_noise)
48
  output1 = proc1(queue.get())
49
  return output1
 
51
  def send_it2(inputs, noise_level, proc1=proc1):
52
  prompt_with_noise = add_random_noise(inputs, noise_level)
53
  while queue.qsize() >= queue_threshold:
54
+ time.sleep()
55
  queue.put(prompt_with_noise)
56
  output2 = proc1(queue.get())
57
  return output2
 
59
  def send_it3(inputs, noise_level, proc1=proc1):
60
  prompt_with_noise = add_random_noise(inputs, noise_level)
61
  while queue.qsize() >= queue_threshold:
62
+ time.sleep()
63
  queue.put(prompt_with_noise)
64
  output3 = proc1(queue.get())
65
  return output3
 
67
  def send_it4(inputs, noise_level, proc1=proc1):
68
  prompt_with_noise = add_random_noise(inputs, noise_level)
69
  while queue.qsize() >= queue_threshold:
70
+ time.sleep()
71
  queue.put(prompt_with_noise)
72
  output4 = proc1(queue.get())
73
  return output4
 
75
  def send_it5(inputs, noise_level, proc1=proc1):
76
  prompt_with_noise = add_random_noise(inputs, noise_level)
77
  while queue.qsize() >= queue_threshold:
78
+ time.sleep()
79
  queue.put(prompt_with_noise)
80
  output5 = proc1(queue.get())
81
  return output5
 
83
  def send_it6(inputs, noise_level, proc1=proc1):
84
  prompt_with_noise = add_random_noise(inputs, noise_level)
85
  while queue.qsize() >= queue_threshold:
86
+ time.sleep()
87
  queue.put(prompt_with_noise)
88
  output6 = proc1(queue.get())
89
  return output6
 
91
  def send_it7(inputs, noise_level, proc1=proc1):
92
  prompt_with_noise = add_random_noise(inputs, noise_level)
93
  while queue.qsize() >= queue_threshold:
94
+ time.sleep()
95
  queue.put(prompt_with_noise)
96
  output7 = proc1(queue.get())
97
  return output7
 
99
  def send_it8(inputs, noise_level, proc1=proc1):
100
  prompt_with_noise = add_random_noise(inputs, noise_level)
101
  while queue.qsize() >= queue_threshold:
102
+ time.sleep()
103
  queue.put(prompt_with_noise)
104
  output8 = proc1(queue.get())
105
  return output8
 
107
 
108
  def get_prompts(prompt_text):
109
  while queue.qsize() >= queue_threshold:
110
+ time.sleep()
111
  queue.put(prompt_text)
112
  output = text_gen(queue.get())
113
  return output