CDCgov / cfa-viral-lineage-model

Apache License 2.0
5 stars 0 forks source link

Simulation output path handling #8

Closed afmagee42 closed 3 weeks ago

afmagee42 commented 1 month ago

run_simulation_study.py currently writes a csv with the call .write_csv("out/sim_study.csv").

We should (1) check if this directory exists before trying to write to it and (2) create the path in a system-agnostic way (presumably with os.path.join()?).

swo commented 1 month ago

the pretty way is:

from pathlib import Path
out_path = Path("/path/to/whatever") # you need to discover this in some way
whatever.write_csv(out_path / "sim_study.csv")