Skip to content

Commit

Permalink
Merge pull request #127 from NASA-IMPACT/fmask_4_5_update
Browse files Browse the repository at this point in the history
Use Fmask wrapper script to invoke Fmask_4_5.
  • Loading branch information
sharkinsspatial authored Jan 28, 2022
2 parents 1da681a + de3628d commit 58a2824
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions scripts/sentinel_granule.sh
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,6 @@ unzip -q "$safezip" -d "$granuledir"
grandir_id=$(get_s2_granule_dir "${safedirectory}")
safegranuledir="${safedirectory}/GRANULE/${grandir_id}"

# Run derive_s2ang

# For new SAFE format locate MTD_TL.xml
# For older SAFE formata locate S2[A|B]_OPER_MTD_*.xml
xml=$(find "$safegranuledir" -maxdepth 1 -type f -name "*.xml")
Expand All @@ -56,6 +54,7 @@ else
detfoo06=$(get_detector_footprint "$safedirectory")
fi

# Run derive_s2ang
echo "Running derive_s2ang"
derive_s2ang "$xml" "$detfoo06" "$detfoo" "$angleoutput"

Expand All @@ -68,7 +67,7 @@ cloud_cover_valid=$(check_sentinel_clouds "$xml_safe")

cd "$safegranuledir"
# Run Fmask
/usr/local/MATLAB/application/run_Fmask_4_4.sh /usr/local/MATLAB/v910 >> fmask_out.txt
run_Fmask.sh >> fmask_out.txt
wait
fmask_file=$(cat fmask_out.txt)
echo "$fmask_file"
Expand Down

0 comments on commit 58a2824

Please sign in to comment.