Skip to content

Commit

Permalink
Allow subsequent notebooks to change their directories for relative i…
Browse files Browse the repository at this point in the history
…mport
  • Loading branch information
mam10eks committed Nov 25, 2023
1 parent 2f7d470 commit 87c1ee5
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions tira-ir-starters/pyterrier/run-pyterrier-notebook.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,9 @@ def parse_args():

def main(args):
os.environ['TIRA_INPUT_DIRECTORY'] = os.path.abspath(args.input)
os.environ['TIRA_INPUT_DATASET'] = os.path.abspath(args.input)
os.environ['TIRA_OUTPUT_DIRECTORY'] = os.path.abspath(args.output)
os.environ['TIRA_OUTPUT_DIR'] = os.path.abspath(args.output)

if args.chdir:
print(f'Change directory to allow relative imports to "{args.chdir}".', flush=True)
Expand Down

0 comments on commit 87c1ee5

Please sign in to comment.