Skip to content

Commit 9812070

Browse files
authored
Merge pull request #15267 from johodges/master
Python: improve cross-platform support for FDS_validation_script.py
2 parents ad2eaf2 + 558fe2d commit 9812070

File tree

1 file changed

+10
-10
lines changed

1 file changed

+10
-10
lines changed

Utilities/Python/FDS_validation_script.py

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
import subprocess
44
import fdsplotlib
55
import importlib
6+
import os, runpy
67
importlib.reload(fdsplotlib) # use for development (while making changes to fdsplotlib.py)
78

89
# # Scripts to run prior to dataplot
@@ -41,16 +42,15 @@
4142
# plot_range=["all"]) # see notes below on plot_range
4243

4344
# Special cases
44-
45-
print("Beyler_Hood..."); subprocess.run(["python","./scripts/Beyler_Hood.py"])
46-
print("BRE_LEMTA_Sprays..."); subprocess.run(["python","./scripts/BRE_LEMTA_Sprays.py"])
47-
print("FM_FPRF_Datacenter..."); subprocess.run(["python","./scripts/FM_FPRF_Datacenter.py"])
48-
print("Heskestad_Flame_Height_2..."); subprocess.run(["python","./scripts/Heskestad_Flame_Height_2.py"])
49-
print("McCaffrey_Plume..."); subprocess.run(["python","./scripts/McCaffrey_Plume.py"])
50-
print("Sandia_Pools..."); subprocess.run(["python","./scripts/Sandia_Pools.py"])
51-
print("TUS_Facade..."); subprocess.run(["python","./scripts/TUS_Facade_contours.py"])
52-
print("USFS_Deep_Fuel_Beds..."); subprocess.run(["python","./scripts/USFS_Deep_Fuel_Beds.py"])
53-
print("Wu_Bakar_Tunnels..."); subprocess.run(["python","./scripts/Wu_Bakar_Tunnels.py"])
45+
print("Beyler_Hood..."); runpy.run_path("./scripts/Beyler_Hood.py", run_name="__main__")
46+
print("BRE_LEMTA_Sprays..."); runpy.run_path("./scripts/BRE_LEMTA_Sprays.py", run_name="__main__")
47+
print("FM_FPRF_Datacenter..."); runpy.run_path("./scripts/FM_FPRF_Datacenter.py", run_name="__main__")
48+
print("Heskestad_Flame_Height_2..."); runpy.run_path("./scripts/Heskestad_Flame_Height_2.py", run_name="__main__")
49+
print("McCaffrey_Plume..."); runpy.run_path("./scripts/McCaffrey_Plume.py", run_name="__main__")
50+
print("Sandia_Pools..."); runpy.run_path("./scripts/Sandia_Pools.py", run_name="__main__")
51+
print("TUS_Facade..."); runpy.run_path("./scripts/TUS_Facade_contours.py", run_name="__main__")
52+
print("USFS_Deep_Fuel_Beds..."); runpy.run_path("./scripts/USFS_Deep_Fuel_Beds.py", run_name="__main__")
53+
print("Wu_Bakar_Tunnels..."); runpy.run_path("./scripts/Wu_Bakar_Tunnels.py", run_name="__main__")
5454

5555
print("Python validation scripts completed successfully!")
5656

0 commit comments

Comments
 (0)