drewpendergrass / CHEEREIO

This repository contains the code for CHEEREIO, which supports data assimilation and emissions inversions for arbitrary runs of the GEOS-Chem chemical transport model via an ensemble approach (i.e. without the model adjoint).
MIT License
10 stars 4 forks source link

ValueError: need at least one array to concatenate #17

Closed HuiruZhong closed 1 month ago

HuiruZhong commented 1 month ago

In the GC_to_sat_levels function at line 350 of tropomi_tools.py, the condition if species == "CO" or "NO2": should be written as if species == "CO" or species == "NO2":. Otherwise, it will always return True, since 'NO2' is treated as a non-empty string. If the species is CH4, this could cause GC_on_sat = np.concatenate(GC_on_sat_list, axis=0) to return an empty list when there aren't many observations.

HuiruZhong commented 1 month ago

When it comes to East Asia, TROPOMI had no satellite data from July 26th to August 29th, 2022

drewpendergrass commented 1 month ago

Thanks for pointing out the GC_to_sat_levels bug -- this has actually already been fixed in the dev branch, and will be fixed in version 1.4 when it is released. In the meantime, rewrite the line as you mentioned and it will speed up run times for methane and fix the empty list error. TROPOMI operational data is missing in that period and in a similar time of year in 2023. This is apparently because of missing VIIRS data.