From 6e0fd31fb6f1209fd2898797497bfb40f34c8c03 Mon Sep 17 00:00:00 2001 From: Israel Roldan Date: Thu, 18 Apr 2024 12:44:12 -0600 Subject: [PATCH] Updated the function get relative paths for benchmarks. --- benchmarks/benchmark_base.py | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/benchmarks/benchmark_base.py b/benchmarks/benchmark_base.py index 1d8ec4e5309..0c86b08f6bb 100644 --- a/benchmarks/benchmark_base.py +++ b/benchmarks/benchmark_base.py @@ -28,13 +28,9 @@ class BenchmarkBase: # the total time for all the repetitions for each benchmark. timeout = 600 - @staticmethod - def split_path(path): - return path.split('/') - def get_relative_path(self, partial_path: str): path = dirname(realpath(__file__)) - targets = self.split_path(partial_path) + targets = Path(partial_path).parts for target in targets: path = join(path, target)