| Total Complexity | 2 |
| Total Lines | 24 |
| Duplicated Lines | 0 % |
| Changes | 0 | ||
| 1 | # Author: Simon Blanke |
||
| 2 | # Email: [email protected] |
||
| 3 | # License: MIT License |
||
| 4 | |||
| 5 | |||
| 6 | class SearchStatistics: |
||
| 7 | def __init__(self): |
||
| 8 | super().__init__() |
||
| 9 | |||
| 10 | self.nth_iter = 0 |
||
| 11 | |||
| 12 | self.n_init_total = 0 |
||
| 13 | self.n_iter_total = 0 |
||
| 14 | |||
| 15 | def init_stats(func): |
||
| 16 | def wrapper(self, *args, **kwargs): |
||
| 17 | self.n_init_search = 0 |
||
| 18 | self.n_iter_search = 0 |
||
| 19 | |||
| 20 | res = func(self, *args, **kwargs) |
||
| 21 | return res |
||
| 22 | |||
| 23 | return wrapper |
||
| 24 |