User Tools

Site Tools


wiki:exercise6a

Exercise 6a: Create the cloud mask

In this exercise, the following tools will be used:

  • pktools: pkgetmask, pkfilter, pkreclass, pkdsm2shadow
  • bash: cat, redirect

Create a directory for this exercise

mkdir -p ${OUTPUTDIR}/exercise6

Create a colour table

cat > ${OUTPUTDIR}/exercise6/cloudmask_ct.txt <<EOF
0 0 0 0 255
1 255 255 255 255
EOF

Create the cloud mask using the thresholds found in exercise 5a

pkgetmask -i ${LANDSATDIR}/${LANDSATIMG} -ot Byte -b 0 -min 0 -max 150 -b 3 -min 0 -max 150 -b 6 -min 140 -max 256 -o ${OUTPUTDIR}/exercise6/cloudmask.tif -data 0 -nodata 1 -ct ${OUTPUTDIR}/exercise6/cloudmask_ct.txt
wiki/exercise6a.txt · Last modified: 2017/12/05 22:53 (external edit)