Start testing with a progress bar.
(self)
| 50 | yield from self.ds |
| 51 | |
| 52 | def start(self): |
| 53 | """ |
| 54 | Start testing with a progress bar. |
| 55 | """ |
| 56 | if not self._reset_called: |
| 57 | self.ds.reset_state() |
| 58 | itr = self.ds.__iter__() |
| 59 | if self.warmup: |
| 60 | for _ in tqdm.trange(self.warmup, **get_tqdm_kwargs()): |
| 61 | next(itr) |
| 62 | # add smoothing for speed benchmark |
| 63 | with get_tqdm(total=self.test_size, |
| 64 | leave=True, smoothing=0.2) as pbar: |
| 65 | for idx, dp in enumerate(itr): |
| 66 | pbar.update() |
| 67 | if idx == self.test_size - 1: |
| 68 | break |
| 69 | |
| 70 | |
| 71 | class BatchData(ProxyDataFlow): |
no test coverage detected