Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Simplify codes #928

Merged
merged 23 commits into from
Apr 28, 2023
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Update compositeDiurnalStatistics.py
  • Loading branch information
lee1043 committed Apr 28, 2023
commit 54e73758eed779c2f1cba3aa7cd057b0cb000044
3 changes: 1 addition & 2 deletions pcmdi_metrics/diurnal/scripts/compositeDiurnalStatistics.py
Original file line number Diff line number Diff line change
Expand Up @@ -173,8 +173,7 @@ def compute(params):
str(args.lastyear),
)
LSToutfile = "%s_%s_LocalSolarTimes.nc" % (varbname, dataname)
if not os.path.exists(args.results_dir):
os.makedirs(args.results_dir)
os.makedirs(args.results_dir, exist_ok=True)
f = cdms2.open(os.path.join(args.results_dir, avgoutfile), "w")
g = cdms2.open(os.path.join(args.results_dir, stdoutfile), "w")
h = cdms2.open(os.path.join(args.results_dir, LSToutfile), "w")
Expand Down