Created with:
Package | Version |
---|---|
SatPy | 0.9.0 |
PyResample | 1.10.1 |
Trollimage | 1.5.3 |
PyKdtree | 1.3.1 |
from satpy.scene import Scene
from glob import glob
scn = Scene(
filenames=glob("/home/a000680/data/polar_in/direct_readout/npp/lvl1/npp_20150420_1202_18019/*"),
reader='viirs_sdr')
/home/a000680/.local/lib/python2.7/site-packages/h5py/__init__.py:36: FutureWarning: Conversion of the second argument of issubdtype from `float` to `np.floating` is deprecated. In future, it will be treated as `np.float64 == np.dtype(float).type`. from ._conv import register_converters as _register_converters
from satpy.resample import get_area_def
areaid = 'eurol'
areadef = get_area_def(areaid)
composite = 'true_color_lowres'
scn.load([composite])
newscn = scn.resample(areadef)
newscn.show(composite)
<trollimage.xrimage.XRImage at 0x7f9ba408e250>
prfx = newscn.start_time.strftime('%Y%m%d%H%M')
newscn.save_dataset(
composite, './true_color_rayleigh_only_{0}_{1}.png'.format(prfx, areaid))
/home/a000680/.local/lib/python2.7/site-packages/dask/local.py:271: RuntimeWarning: invalid value encountered in less return func(*args2) /home/a000680/.local/lib/python2.7/site-packages/dask/local.py:271: RuntimeWarning: invalid value encountered in log10 return func(*args2)