Questions tagged [metpy]

MetPy is a collection of tools in Python for reading, visualizing and performing calculations with weather data.

MetPy is a Python library for reading, visualizing and performing calculations with weather data. It leverages heavily the xarray library for its data model, though it is designed to work on any data that you can get into a numpy array--sometimes needing unit information, which is provided through the Pint library.

Resources

211 questions
0
votes
1 answer

Interpolate_to_grid returns all nans

Practicing with MetPy Monday interpolate_to_grid for metar data and I successfully got the mslp grid to work. Moving on to Potential temperature and the result has been all nan. When it "works". When it doesnt work, I get a set of errors that dont…
jimmyc
  • 1
  • 2
0
votes
1 answer

adding mixing lines across all pressures in skewT metpy

I can plot a standard SkewT chart with mixing lines up to the default of p=600hPa, using the default call plot_mixing_lines() But I wanted to extend them up to the upper troposphere. I tried to do the following: import matplotlib.pyplot as…
ClimateUnboxed
  • 7,106
  • 3
  • 41
  • 86
0
votes
0 answers

Kernel dying in Jupyter notebooks with metpy

running any metpy function is fine till plotting when the kernel repeatedly dies. I think this may be a hardware issue but curious for answers
0
votes
1 answer

Error creating Satellite images from THREDDS server after MetPy 0.12->1.1 upgrade

Upgraded MetPy to 1.1 and my ability to produce satellite images from a THREDDS server is no longer working. I isolated the part that is causing me issues. Example: #!/usr/bin/python3 import metpy from siphon.catalog import TDSCatalog cat_e =…
djb
  • 1
0
votes
2 answers

Which formula is used to calculate relative humidity from dewpoint with metpy?

I am using MetPy to calculate relative humidity from dewpoint and temperature. The resulting data looks pretty good, with values between 0.23 and 0.95 (intuitively seems to be ok). My problem is, there is no accurate information about which formula…
0
votes
1 answer

Best place to start finding out more background on the NDFD forecast?

My apologies for not asking a programming related question, but I'm not sure where else to start. I have been making animation plots of the NDFD rainfall forecast, and I am noticing a lot of curious variations in the rainfall values along state…
0
votes
1 answer

Unable to import gradient_richardson_number from metpy.calc

I'm trying to import gradient_richardson_number from metpy.calc with the error: Traceback (most recent call last): File "", line 1, in ImportError: cannot import name 'gradient_richardson_number' I can import all other packages from metpy.calc.…
0
votes
1 answer

ValueError using MetPy and xarray

I am trying to use some scripts from https://unidata.github.io/MetPy/latest/examples/Four_Panel_Map.html#sphx-glr-download-examples-four-panel-map-py to make weather charts but i found this problem running this script: Traceback (most recent call…
Efece
  • 3
  • 2
0
votes
3 answers

How do I increase text size in metpy using declarative syntax?

Is there a way to access the native matplotlib objects that the declarative syntax makes use of internally?
0
votes
1 answer

What is the best way to plot SODAR vertical wind profiles over time in python?

I am able to do the typical wind barb and vector plots. I am looking to do a color contour kind of map and can't figure out how to do it. Does anyone have any ideas? Is there a package for this in MetPy? There are some examples in the article in the…
0
votes
1 answer

CAPE_CIN returning incorrect values

I'm interested in calculating CAPE from past soundings. I've done some test calculations and for some reason my CAPE values are not agreeing with those that are provided along with current soundings. e.g., see the latest sounding from Boa Vista,…
0
votes
2 answers

How can I get the effective storm helicity and effective shear values for this metpy calculation?

I am trying to use the metpy.calc functions to get supercell composite values, as shown here: Supercell Composite However, I can't seem to find anywhere how to calculate the effective storm helicity, and effective shear. I've got storm-relative…
0
votes
1 answer

AttributeError: module 'metpy.units' has no attribute 'knots'

I am trying to add basic units to my array to do calculations with Metpy. Using the function call metpy.units.meters (or .knots or .degrees) is not working. Here is my code snippet: import metpy.units as mpunits ... wind_speed = webSKNT.values *…
laika532
  • 3
  • 1
0
votes
1 answer

Question about the coordinates of metpy cross section

I followed the code to draw the cross section figure on this site. (https://unidata.github.io/MetPy/latest/examples/cross_section.html#sphx-glr-examples-cross-section-py) In the example, running the following code will produce this…
정지훈
  • 3
  • 1
0
votes
2 answers

Resampling and re-projecting weather satellite image from global view to regional extent

After reading and plotting the satellite image on the notebook, I am finding it difficult to resample and re-project (projection = PlateCarre) to regional extent (extent = -1, 19, -1, 17). I will appreciate if the Coastline is plotted on the image.…
Dayo
  • 7
  • 2