Skip to content

Commit 265bfc0

Browse files
authored
Merge pull request #2390 from verilog-to-routing/run_vtr_flow_tmp_dir
Change temp_dir default to abs dir
2 parents a0dd712 + 1309ec2 commit 265bfc0

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

vtr_flow/scripts/run_vtr_flow.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
import socket
1111
from datetime import datetime
1212
from collections import OrderedDict
13+
import os
1314

1415
# pylint: disable=wrong-import-position, import-error
1516
sys.path.insert(0, str(Path(__file__).resolve().parent / "python_libs"))
@@ -186,8 +187,8 @@ def vtr_command_argparser(prog=None):
186187

187188
house_keeping.add_argument(
188189
"-temp_dir",
189-
default=None,
190-
help="Directory to run the flow in (will be created if non-existent).",
190+
default=os.getcwd() + "/temp",
191+
help="Absolute Directory to run the flow in (will be created if non-existent).",
191192
)
192193

193194
house_keeping.add_argument("-name", default=None, help="Name for this run to be output.")
@@ -521,10 +522,9 @@ def vtr_command_main(arg_list, prog=None):
521522
# Load the arguments
522523
args, unknown_args = vtr_command_argparser(prog).parse_known_args(arg_list)
523524
error_status = "Error"
524-
if args.temp_dir is None:
525-
temp_dir = Path("./temp")
526-
else:
527-
temp_dir = Path(args.temp_dir)
525+
526+
assert args.temp_dir
527+
temp_dir = Path(args.temp_dir)
528528
# Specify how command should be run
529529
command_runner = vtr.CommandRunner(
530530
track_memory=args.track_memory_usage,

0 commit comments

Comments
 (0)