Skip to content

Commit

Permalink
replace globals by locals (#1802)
Browse files Browse the repository at this point in the history
  • Loading branch information
ReimarBauer authored Jun 1, 2023
1 parent ee2962f commit 04d030b
Showing 1 changed file with 1 addition and 8 deletions.
9 changes: 1 addition & 8 deletions mslib/utils/thermolib.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,14 +27,10 @@
"""

import numpy as np

from mslib.utils.units import units, check_units

from metpy.package_tools import Exporter
from metpy.constants import Rd, g
from metpy.xarray import preprocess_and_wrap

exporter = Exporter(globals())
from mslib.utils.units import units, check_units


def rel_hum(p, t, q):
Expand Down Expand Up @@ -142,7 +138,6 @@ def omega_to_w(omega, p, t):
_HEIGHT, _TEMPERATURE, _PRESSURE, _TEMPERATURE_GRADIENT = 0, 1, 2, 3


@exporter.export
@preprocess_and_wrap(wrap_like='height')
@check_units('[length]')
def flightlevel2pressure(height):
Expand Down Expand Up @@ -194,7 +189,6 @@ def flightlevel2pressure(height):
return p if is_array else p[0]


@exporter.export
@preprocess_and_wrap(wrap_like='pressure')
@check_units('[pressure]')
def pressure2flightlevel(pressure):
Expand Down Expand Up @@ -247,7 +241,6 @@ def pressure2flightlevel(pressure):
return z if is_array else z[0]


@exporter.export
@preprocess_and_wrap(wrap_like='height')
@check_units('[length]')
def isa_temperature(height):
Expand Down

0 comments on commit 04d030b

Please sign in to comment.