Skip to content

Instantly share code, notes, and snippets.

@benfoxall
Last active March 31, 2022 15:15
Show Gist options
  • Star 4 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save benfoxall/2741f5383528e6d2bc4c609b812310f1 to your computer and use it in GitHub Desktop.
Save benfoxall/2741f5383528e6d2bc4c609b812310f1 to your computer and use it in GitHub Desktop.
Generate video of satellite imagery
# Extract frames from GEOS Image Viewer to generate a video
# https://www.star.nesdis.noaa.gov/goes/fulldisk_band.php?sat=G16&band=GEOCOLOR&length=12&dim=1
mkdir -p images output
BASE=https://cdn.star.nesdis.noaa.gov/GOES16/ABI/FD/GEOCOLOR/
DIM=1808x1808
curl $BASE \
| grep -o -e "\".*GEOCOLOR-$DIM.jpg\"" \
| sed -e 's/"//g' \
| wget -nc -P images --base $BASE -i -
ffmpeg -y -framerate 10 -pattern_type glob -i 'images/*.jpg' -c:v libx264 -pix_fmt yuv420p output/10fps.mp4
ffmpeg -y -framerate 30 -pattern_type glob -i 'images/*.jpg' -c:v libx264 -pix_fmt yuv420p output/30fps.mp4
ffmpeg -y -framerate 60 -pattern_type glob -i 'images/*.jpg' -c:v libx264 -pix_fmt yuv420p output/60fps.mp4
ffmpeg -y -framerate 60 -pattern_type glob -i 'images/*.jpg' -c:v libx264 -pix_fmt yuv420p -vf scale=1024:1024 output/60fps-1024.mp4
ffmpeg -y -framerate 60 -pattern_type glob -i 'images/*.jpg' -c:v libx264 -pix_fmt yuv420p -vf scale=512:512 output/60fps-512.mp4
ffmpeg -y -framerate 30 -pattern_type glob -i 'images/*.jpg' -c:v libvpx -crf 4 -b:v 1M output/30fps-1m.webm
ffmpeg -y -framerate 30 -pattern_type glob -i 'images/*.jpg' -c:v libvpx -crf 4 -b:v 5M output/30fps-5m.webm
ffmpeg -y -framerate 30 -pattern_type glob -i 'images/*.jpg' -c:v libvpx -crf 4 -b:v 10M output/30fps-10m.webm
ffmpeg -y -framerate 30 -pattern_type glob -i 'images/*.jpg' -c:v libvpx -crf 4 -b:v 10M -vf scale=1024:1024 output/30fps-10m-1024.webm
ffmpeg -y -framerate 30 -pattern_type glob -i 'images/*.jpg' -c:v libvpx -crf 4 -b:v 10M -vf scale=512:512 output/30fps-10m-512.webm
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment