chrisblodgett commited on
Commit
4cadf36
·
1 Parent(s): 2fbd96d

made delay longer

Browse files
Files changed (1) hide show
  1. visualizing_gaussian.py +3 -7
visualizing_gaussian.py CHANGED
@@ -22,12 +22,7 @@ class CustomDeque(deque):
22
  super().append(x)
23
 
24
 
25
-
26
  global_prob = []
27
-
28
-
29
-
30
-
31
  chart_history = CustomDeque(maxlen=4)
32
 
33
  def get_dice_prob_bargraph(events_num,equal,color='#7a5af5'):
@@ -171,8 +166,9 @@ def run_simulation(running,num_sums=50,num_dice=30,color='yellow'):
171
  elapsed_time = end_time - start_time
172
  # print(f"Setting the layout to fig took {elapsed_time:.4f}")
173
  start_time = time.time()
174
- yield layout
175
- time.sleep(.15)
 
176
  end_time = time.time()
177
  elapsed_time = end_time - start_time
178
  # print(f"Yield took {elapsed_time:.4f}")
 
22
  super().append(x)
23
 
24
 
 
25
  global_prob = []
 
 
 
 
26
  chart_history = CustomDeque(maxlen=4)
27
 
28
  def get_dice_prob_bargraph(events_num,equal,color='#7a5af5'):
 
166
  elapsed_time = end_time - start_time
167
  # print(f"Setting the layout to fig took {elapsed_time:.4f}")
168
  start_time = time.time()
169
+ if not (i+1) % 10: # only update every 10th sum
170
+ yield layout
171
+ #time.sleep(.15)
172
  end_time = time.time()
173
  elapsed_time = end_time - start_time
174
  # print(f"Yield took {elapsed_time:.4f}")