From 44287de6fb4ac71285f6d8c9b56b8d1909355ad6 Mon Sep 17 00:00:00 2001 From: Israel Roldan Date: Thu, 18 Apr 2024 18:59:23 -0600 Subject: [PATCH] Updated the function get relative paths for benchmarks. --- benchmarks/benchmark_base.py | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/benchmarks/benchmark_base.py b/benchmarks/benchmark_base.py index 1d8ec4e5309..c4498396b74 100644 --- a/benchmarks/benchmark_base.py +++ b/benchmarks/benchmark_base.py @@ -29,12 +29,9 @@ class BenchmarkBase: timeout = 600 @staticmethod - def split_path(path): - return path.split('/') - - def get_relative_path(self, partial_path: str): + def get_relative_path(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)