Skip to content

NAM CAPE+Wetbulb pressure index error #9

Description

@jsillin
CAPE + Wetbulb
Traceback (most recent call last):
  File "C:\Users\Jack\Documents\soundingmaps_production\interactive_skewmap.py", line 365, in <module>
    smap.plot_soundings(fig,ax1,prs_temps,prs_relh,sfc_pressure,centerlat,centerlon,domainsize,model,cape=cape_bool,wetbulb=wetbulb_bool)
  File "C:\Users\Jack\Documents\soundingmaps_production\soundingmaps.py", line 138, in plot_soundings
    parcel_prof = mpcalc.parcel_profile(pres_abv_ground,abv_sfc_temp[0].data*units.degC,abv_sfc_dewp[0])
  File "C:\Users\Jack\anaconda3\envs\skododev\lib\site-packages\metpy\xarray.py", line 1216, in wrapper
    result = func(*bound_args.args, **bound_args.kwargs)
  File "C:\Users\Jack\anaconda3\envs\skododev\lib\site-packages\metpy\units.py", line 246, in wrapper
    return func(*args, **kwargs)
  File "C:\Users\Jack\anaconda3\envs\skododev\lib\site-packages\metpy\calc\thermo.py", line 744, in parcel_profile
    _, _, _, t_l, _, t_u = _parcel_profile_helper(pressure, temperature, dewpoint)
  File "C:\Users\Jack\anaconda3\envs\skododev\lib\site-packages\metpy\calc\thermo.py", line 904, in _parcel_profile_helper
    press_lcl, temp_lcl = lcl(pressure[0], temperature, dewpoint)
  File "C:\Users\Jack\anaconda3\envs\skododev\lib\site-packages\pint\quantity.py", line 1851, in __getitem__
    return type(self)(self._magnitude[key], self._units)
IndexError: index 0 is out of bounds for axis 0 with size 0

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions