Skip to content

Unit/Pint Troubles #1641

Answered by DanielAdriaansen
jsillin asked this question in Q&A
Dec 30, 2020 · 2 comments · 11 replies
Discussion options

You must be logged in to vote

Since you're using 0.12.1, try this:

h7_fgen = mpcalc.frontogenesis(t7.values,u7.values,v7.values,dx,dy)

I'm not sure 0.12.1 can handle a pint quantity wrapped by a DataArray but I think 1.0 can. By using values, you'll pull out just the pint quantity object from the DataArray object for frontogenesis() to work with.

Replies: 2 comments 11 replies

Comment options

You must be logged in to vote
8 replies
@jsillin
Comment options

@jthielen
Comment options

@jsillin
Comment options

@jthielen
Comment options

@jthielen
Comment options

Comment options

You must be logged in to vote
3 replies
@jsillin
Comment options

@jthielen
Comment options

@jsillin
Comment options

Answer selected by dopplershift
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants