我正在尝试获取文件有效权限 。 最好的方法是什么? 我正在尝试使用win32security但GetEffectiveRightsFromAcl(trustee)函数需要PyTRUSTEE参数。 而且我不知道如何正确设置它。 结果,我需要获得与在PowerShell中调用Get- ...
提示:本站收集StackOverFlow近2千万问答,支持中英文搜索,鼠标放在语句上弹窗显示对应的参考中文或英文, 本站还提供 中文繁体 英文版本 中英对照 版本,有任何建议请联系yoyou2525@163.com。
我正在尝试使用metpy.calc 函数来获取supercell 复合值,如下所示: Supercell Composite
但是,我似乎在任何地方都找不到如何计算有效风暴螺旋度和有效剪切力。 我的 grib2 数据中有风暴相对螺旋度,但我如何获得有效的?
谢谢!
从 1.0 版开始,MetPy 不具备计算有效 SRH (ESRH) 和有效体积剪切 (EBS) 的功能。
ESRH 是在“有效风暴流入层”内计算的 SRH,它是由地块特征 CAPE >= 100 J/kg 和 CIN >= -250 J/kg 的下边界定义的风暴的最低垂直区域,继续直到不再满足其中任何一个标准。 EBS 是风暴的整体切变,在其深度而非标准垂直范围内归一化。
这是计算有效风暴相对螺旋度和有效体积剪切的有效层的快速尝试。 这使用 MetPy 函数来计算包裹温度曲线以及 CAPE 和 CIN 值。
然后可以使用来自此 function 的 output 设置适当的层的深度和底部,以计算风暴相对螺旋度和体积剪切(然后计算诸如超级单体复合参数之类的东西)。
我已经在 1999 年 5 月 4 日 00 UTC 从 KOUN 上对其进行了测试,它给出了一个合理的答案,但尚未经过广泛测试。
# Effective Shear Algorithm
def effective_layer(p, T, Td, h, height_layer=False):
'''This function determines the effective inflow layer for a convective sounding.
Input:
- p: sounding pressure with units
- T: sounding temperature with units
- Td: sounding dewpoint temperature with units
- h: sounding heights with units
Returns:
- pbot/hbot, ptop/htop: pressure/height of the bottom level, pressure/height of the top level
'''
from metpy.calc import parcel_profile, cape_cin
from metyp.units import units
import numpy as np
pbot = None
for i in range(p.shape[0]):
prof = parcel_profile(p[i:], T[i], Td[i])
sbcape, sbcin = cape_cin(p[i:], T[i:], Td[i:], prof)
if sbcape >= 100 * units('J/kg') and sbcin > -250 * units('J/kg'):
pbot = p[i]
hbot = h[i]
bot_idx = i
break
if not pbot:
return None, None
for i in range(bot_idx+1, p.shape[0]):
prof = parcel_profile(p[i:], T[i], Td[i])
sbcape, sbcin = cape_cin(p[i:], T[i:], Td[i:], prof)
if sbcape < 100 * units('J/kg') or sbcin < -250 * units('J/kg'):
ptop = p[i]
htop = h[i]
break
if height_layer:
return hbot, htop
else:
return pbot, ptop
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.