diff options
Diffstat (limited to 'resources/tools/dash/app/pal/data/data.py')
-rw-r--r-- | resources/tools/dash/app/pal/data/data.py | 30 |
1 files changed, 23 insertions, 7 deletions
diff --git a/resources/tools/dash/app/pal/data/data.py b/resources/tools/dash/app/pal/data/data.py index a3b6c2a478..3d9b8b1664 100644 --- a/resources/tools/dash/app/pal/data/data.py +++ b/resources/tools/dash/app/pal/data/data.py @@ -151,13 +151,29 @@ class Data: def read_stats(self, days=None): """Read Suite Result Analysis data partition from parquet. """ - lambda_f = lambda part: True if part["stats_type"] == "sra" else False - - return self._create_dataframe_from_parquet( - path=self._get_path("statistics"), - partition_filter=lambda_f, - columns=None, # Get all columns. - days=days + l_stats = lambda part: True if part["stats_type"] == "sra" else False + l_mrr = lambda part: True if part["test_type"] == "mrr" else False + l_ndrpdr = lambda part: True if part["test_type"] == "ndrpdr" else False + + return ( + self._create_dataframe_from_parquet( + path=self._get_path("statistics"), + partition_filter=l_stats, + columns=self._get_columns("statistics"), + days=days + ), + self._create_dataframe_from_parquet( + path=self._get_path("statistics-trending"), + partition_filter=l_mrr, + columns=self._get_columns("statistics-trending"), + days=days + ), + self._create_dataframe_from_parquet( + path=self._get_path("statistics-trending"), + partition_filter=l_ndrpdr, + columns=self._get_columns("statistics-trending"), + days=days + ) ) def read_trending_mrr(self, days=None): |