def test_make_benchmark_jvalue_plots(): refdata = 'GCCData/JValuesTest.nc4' refstr = 'GCC Test Data' devdata = 'GCHPData/JValuesTest.nc4' devstr = 'GCHP Test Data' dst = './TestOutput/' subdst = 'make_benchmark_jvalue_plots/' try: bmk.make_benchmark_jvalue_plots(refdata, refstr, devdata, devstr, dst=dst, overwrite=True) print( "make_benchmark_jvalue_plots ran successfully, check output PDFs to visually verify" ) except Exception as e: print("make_benchmark_jvalue_plots failed") raise e
gcc_vs_gcc_devlist = [gcc_vs_gcc_devhco] bmk.make_benchmark_emis_tables(gcc_vs_gcc_reflist, gcc_vs_gcc_refstr, gcc_vs_gcc_devlist, gcc_vs_gcc_devstr, dst=gcc_vs_gcc_plotsdir, interval=sec_per_month, overwrite=True) if plot_jvalues: # Local noon J-values plots print('\n%%% Creating GCC vs. GCC J-value plots %%%') bmk.make_benchmark_jvalue_plots(gcc_vs_gcc_refjv, gcc_vs_gcc_refstr, gcc_vs_gcc_devjv, gcc_vs_gcc_devstr, dst=gcc_vs_gcc_plotsdir, overwrite=True, sigdiff_files=gcc_vs_gcc_sigdiff) if plot_aod: # Column AOD plots print('\n%%% Creating GCC vs. GCC column AOD plots %%%') bmk.make_benchmark_aod_plots(gcc_vs_gcc_refaod, gcc_vs_gcc_refstr, gcc_vs_gcc_devaod, gcc_vs_gcc_devstr, dst=gcc_vs_gcc_plotsdir, overwrite=True, sigdiff_files=gcc_vs_gcc_sigdiff)
'JValues', bmk_seasons, is_gcc=True) gcc_vs_gcc_devjv = get_filepaths(gcc_vs_gcc_devdir, 'JValues', bmk_seasons, is_gcc=True) # Create seasonal J-values plots for s in range(bmk_nseasons): mon_yr_str = bmk_seasons_names[s] sigdiff_files = gcc_vs_gcc_sigdiff[mon_yr_str] bmk.make_benchmark_jvalue_plots(gcc_vs_gcc_refjv[s], gcc_vs_gcc_refstr, gcc_vs_gcc_devjv[s], gcc_vs_gcc_devstr, dst=gcc_vs_gcc_plotsdir, subdst=mon_yr_str, overwrite=True, sigdiff_files=sigdiff_files) if plot_aod and "FullChem" in bmk_type: # -------------------------------------------------------------- # GCC vs. GCC column AOD plots # (FullChemBenchmark only) # -------------------------------------------------------------- title = '\n%%% Creating GCC vs. GCC {} column AOD plots %%%'.format( bmk_type) print(title) ## Paths to aerosol optical depth data gcc_vs_gcc_refaod = get_filepaths(gcc_vs_gcc_refdir,
# GCC vs GCC J-value plots # -------------------------------------------------------------- if plot_jvalues: print("\n%%% Creating GCC vs. GCC J-value plots %%%") # Diagnostic collection files to read col = "JValues" ref = get_filepath(gcc_vs_gcc_refdir, col, gcc_date) dev = get_filepath(gcc_vs_gcc_devdir, col, gcc_date) # Plot J-values bmk.make_benchmark_jvalue_plots(ref, gcc_vs_gcc_refstr, dev, gcc_vs_gcc_devstr, dst=gcc_vs_gcc_resultsdir, weightsdir=weightsdir, overwrite=True, sigdiff_files=gcc_vs_gcc_sigdiff, spcdb_dir=spcdb_dir) #--------------------------------------------------------------- # GCC vs GCC column AOD plots #--------------------------------------------------------------- if plot_aod: print("\n%%% Creating GCC vs. GCC column AOD plots %%%") # Diagnostic collection files to read col = "Aerosols" ref = get_filepath(gcc_vs_gcc_refdir, col, gcc_date) dev = get_filepath(gcc_vs_gcc_devdir, col, gcc_date)
if plot_jvalues: print("\n%%% Creating GCC vs. GCC J-value plots %%%") # Diagnostic collections to read col = "JValues" # Create J-value plots for each benchmark month for s, bmk_mon in enumerate(bmk_mons): ref = get_filepath(gcc_vs_gcc_refdir, col, bmk_mon) dev = get_filepath(gcc_vs_gcc_devdir, col, bmk_mon) bmk.make_benchmark_jvalue_plots(ref, gcc_vs_gcc_refstr, dev, gcc_vs_gcc_devstr, dst=gcc_vs_gcc_resultsdir, subdst=bmk_mon_yr_strs[s], weightsdir=weightsdir, overwrite=True, spcdb_dir=spcdb_dir) # -------------------------------------------------------------- # GCC vs. GCC column AOD plots # -------------------------------------------------------------- if plot_aod: print("\n%%% Creating GCC vs. GCC column AOD plots %%%") # Diagnostic collections to read col = "Aerosols" # Create AOD plots for each benchmark month
flip_ref=True, flip_dev=True, cmpres=cmpres, dev_sg_params=dev_sg_params, x_extent=roi_x, y_extent=roi_y) if plot_jvalues: # Local noon J-values plots print('\n%%% Creating GCHP vs. GCHP J-value plots %%%') bmk.make_benchmark_jvalue_plots( refjv, refstr, devjv, devstr, dst=plotsdir, overwrite=True, cmpres=cmpres, dev_sg_params=dev_sg_params, x_extent=roi_x, y_extent=roi_y, ) if plot_aod: # Column AOD plots print('\n%%% Creating GCHP vs. GCHP column AOD plots %%%') bmk.make_benchmark_aod_plots(refaod, refstr, devaod, devstr, dst=plotsdir, overwrite=True,