Skip to content

Commit 963b41a

Browse files
committed
Updated heatmap code to save to specified directory correctly
1 parent 23656d2 commit 963b41a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/sharpness/exp_utilities.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -278,7 +278,7 @@ def compute_metrics(
278278
outdir + base_name + "_" + str(len(metrics)) + "_metrics_plots.pdf"
279279
)
280280
else:
281-
output_filename = filename
281+
output_filename = outdir + filename
282282
print(f"\nSaving results to {output_filename}")
283283
F.savefig(output_filename)
284284

@@ -387,7 +387,7 @@ def write_metric_summary_output(
387387
# Close file at the end - but only if we created a file:
388388
if filename != None:
389389
file.close()
390-
with open(filename, "r") as f:
390+
with open(outdir + filename, "r") as f:
391391
output = f.read()
392392
print(output)
393393

0 commit comments

Comments
 (0)