Skip to content

Commit

Permalink
Update compiler.py 75d2e98
Browse files Browse the repository at this point in the history
Co-authored-by: ivy-dev-bot <[email protected]>
  • Loading branch information
Sam-Armstrong and ivy-dev-bot authored Oct 13, 2024
1 parent 46f4839 commit 4f44f06
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions ivy/compiler/compiler.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ def source_to_source(
source: str = "torch",
target: str = "tensorflow",
reuse_existing: bool = True,
output_dir: str = "ivy_transpiled_outputs/",
):
"""Converts a given object (class/function) from one framework to another.
Expand All @@ -39,6 +40,8 @@ def source_to_source(
If False, it will re-translate `object`,
even if it already exists in the directory, and overwrite
the old implementation. Defaults to 'True'.
output_dir (str, optional): The path to the directory where translated files will be saved.
Defaults to 'ivy_transpiled_outputs/' in the current working directory.
Returns:
The translated object."""
Expand All @@ -50,6 +53,7 @@ def source_to_source(
source=source,
target=target,
reuse_existing=reuse_existing,
output_dir=output_dir,
)


Expand Down Expand Up @@ -174,6 +178,7 @@ def transpile(
source: str = "torch",
target: str = "tensorflow",
reuse_existing: bool = True,
output_dir: str = "ivy_transpiled_outputs/",
):
"""Converts a given object (class/function) from one framework to another.
Expand All @@ -192,6 +197,8 @@ def transpile(
If False, it will re-translate `object`,
even if it already exists in the directory, and overwrite
the old implementation. Defaults to 'True'.
output_dir (str, optional): The path to the directory where translated files will be saved.
Defaults to 'ivy_transpiled_outputs/' in the current working directory.
Returns:
The translated object."""
Expand All @@ -203,4 +210,5 @@ def transpile(
source=source,
target=target,
reuse_existing=reuse_existing,
output_dir=output_dir,
)

0 comments on commit 4f44f06

Please sign in to comment.