-
Notifications
You must be signed in to change notification settings - Fork 10
/
using satellite data (modis)
58 lines (38 loc) · 1.83 KB
/
using satellite data (modis)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
Short intro on MODIS data
"Moderate Resolution Imaging Spectrometer (MODIS) is a satellite-based instrument that continuously collects data over the Earth’s surface. Currently, MODIS has the finest temporal resolution of the publicly available remote sensing data, spanning the entire globe every 24 hrs.
MODIS collects data across 36 spectral bands; however, you can choose to work with less bands""
# example Modis satellite data in python (2018, 3 bands selected, 3 layers, etc..)
var dataset = ee.ImageCollection('MODIS/006/MOD14A1')
.filter(ee.Filter.date('2018-01-01', '2018-05-01'));
var fireMaskVis = {
min: 0.0,
max: 6000.0,
bands: ['MaxFRP', 'FireMask', 'FireMask'],
};
Map.setCenter(6.746, 46.529, 2);
Map.addLayer(dataset, fireMaskVis, 'Fire Mask');
# importing useful packages
from glob import glob
import os
import numpy as np
import numpy.ma as ma
import matplotlib.pyplot as plt
import geopandas as gpd
import rasterio as rio
import earthpy as et
import earthpy.spatial as es
import earthpy.plot as ep
# open source for you to use
# Create list of MODIS rasters for surface reflectance
modis_bands_pre_list = glob(
"data/cold-springs-fire/modis/reflectance/07_july_2016/crop/*_sur_refl_b*.tif")
# Sort the list of bands
modis_bands_pre_list.sort()
modis_bands_pre_list
# Identify minimum and maximum values of band 1 (red)
print(modis_bands_pre[1].min(), modis_bands_pre[1].max())
# Identify minimum and maximum values of scaled band 1 (red)
print(modis_bands_pre_scaled[1].min(), modis_bands_pre_scaled[1].max())
Creative commons licencese is part of the code (c) Earth Lab Wasser, Leah, Palomino,
Jenny, & Holdgraf, Chris. (2019, October 30). earthlab/earth-analytics-python-course:
earthlab/earth-analytics-python-course: Version-1.0.1 (Version 1.0.1). Zenodo. http://doi.org/10.5281/zenodo.3523193