Write a sequence of normally distributed histograms to writer.
(writer, tag, mu_sigma_tuples, n=20)
| 99 | |
| 100 | |
| 101 | def WriteHistogramSeries(writer, tag, mu_sigma_tuples, n=20): |
| 102 | """Write a sequence of normally distributed histograms to writer.""" |
| 103 | step = 0 |
| 104 | wall_time = _start_time |
| 105 | for [mean, stddev] in mu_sigma_tuples: |
| 106 | data = [random.normalvariate(mean, stddev) for _ in range(n)] |
| 107 | histo = _MakeHistogram(data) |
| 108 | summary = tf.Summary(value=[tf.Summary.Value(tag=tag, histo=histo)]) |
| 109 | event = tf.Event(wall_time=wall_time, step=step, summary=summary) |
| 110 | writer.add_event(event) |
| 111 | step += 10 |
| 112 | wall_time += 100 |
| 113 | |
| 114 | |
| 115 | def WriteImageSeries(writer, tag, n_images=1): |
no test coverage detected
searching dependent graphs…