Skip to content

Commit

Permalink
fixing bugs
Browse files Browse the repository at this point in the history
  • Loading branch information
aishwariyachakraborty committed Oct 1, 2024
1 parent 4f881a6 commit 6d3c65b
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 7 deletions.
Empty file.
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
"runtime_pipeline_id": "pipeline_id",
"runtime_job_id": "job_id",
"runtime_code_location": ParamsUtils.convert_to_ast(code_location),
"runtime_num_processors": 2,
# "runtime_num_processors": 2,
# sp params
"sp_ikb_file": "src/ikb/ikb_model.csv",
"sp_null_libs_file": "src/ikb/null_libs.csv"
Expand Down
6 changes: 3 additions & 3 deletions transforms/code/semantic_profiler/python/src/sp_transform.py
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ def __init__(self, config: dict[str, Any]):
self.ikb_file = config.get("ikb_file", "../src/ikb/ikb_model.csv")
self.null_libs_file = config.get("null_libs_file", "../src/ikb/null_libs.csv")

def transform(self, table: pa.Table) -> tuple[list[pa.Table], dict[str, Any]]:
def transform(self, table: pa.Table, file_name: str = None) -> tuple[list[pa.Table], dict[str, Any]]:
"""
Put Transform-specific to convert one Table to 0 or more tables. It also returns
a dictionary of execution statistics - arbitrary dictionary
Expand Down Expand Up @@ -100,14 +100,14 @@ def add_input_params(self, parser: ArgumentParser) -> None:
parser.add_argument(
f"--{ikb_file_cli_param}",
type=str,
default="ikb/ikb_model.csv",
default=None,
help="Default IKB file",
)

parser.add_argument(
f"--{null_libs_file_cli_param}",
type=str,
default="ikb/null_libs.csv",
default=None,
help="Default Null Libraries file",
)

Expand Down
4 changes: 2 additions & 2 deletions transforms/code/semantic_profiler/ray/src/sp_local_ray.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,8 @@
"runtime_creation_delay": 0,
"runtime_code_location": ParamsUtils.convert_to_ast(code_location),
# noop params
"sp_ikb_file": "ikb/ikb_model.csv",
"sp_null_libs_file": "ikb/null_libs.csv"
"sp_ikb_file": "src/ikb/ikb_model.csv",
"sp_null_libs_file": "src/ikb/null_libs.csv"
}
if __name__ == "__main__":
# Set the simulated command line args
Expand Down
2 changes: 1 addition & 1 deletion transforms/code/semantic_profiler/ray/test/test_sp_ray.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ def get_test_transform_fixtures(self) -> list[tuple]:
input_dir = os.path.join(src_file_dir, "../test-data/input")
expected_dir = os.path.join(src_file_dir, "../test-data/expected")
runtime_config = {"run_locally": True}
transform_config = {ikb_file_cli_param:"../src/ikb/ikb_model.csv", null_libs_file_cli_param: "../src/ikb/null_libs.csv"}
transform_config = {ikb_file_cli_param: os.path.join(src_file_dir, "../src/ikb/ikb_model.csv"), null_libs_file_cli_param: os.path.join(src_file_dir,"../src/ikb/null_libs.csv")}
fixtures.append(
(
launcher,
Expand Down

0 comments on commit 6d3c65b

Please sign in to comment.