(self)
| 438 | return result |
| 439 | |
| 440 | def get_gc_stats(self) -> list[dict[str, int]]: |
| 441 | gc_stats: list[dict[str, int]] = [] |
| 442 | for key, value in self._data.items(): |
| 443 | if not key.startswith("GC"): |
| 444 | continue |
| 445 | n, _, rest = key[3:].partition("]") |
| 446 | name = rest.strip() |
| 447 | gen_n = int(n) |
| 448 | while len(gc_stats) <= gen_n: |
| 449 | gc_stats.append({}) |
| 450 | gc_stats[gen_n][name] = value |
| 451 | return gc_stats |
| 452 | |
| 453 | def get_optimization_stats(self) -> dict[str, tuple[int, int | None]]: |
| 454 | if "Optimization attempts" not in self._data: |
no test coverage detected