# GOES 16_17_18_19 GOESTOOLS  goesproc configuration file to process GOES-R series products.
# USRADIOGUY.COM Version 04/01/2024
#

# Store all original GOES-16 products.
[[handler]]
type = "image"
origin = "goes16"
directory = "./goes16/{region:short|lower}/{channel:short|lower}/{time:%Y-%m-%d}"
filename = "GOES16_{region:short}_{channel:short}_{time:%Y%m%dT%H%M%SZ}"
format = "jpg"
json = false

  [[handler.map]]
  path = "/usr/share/goestools/ne/ne_50m_admin_0_countries_lakes.json"

  [[handler.map]]
  path = "/usr/share/goestools/ne/ne_50m_admin_1_states_provinces_lakes.json"

# Store all original GOES-18 products.
[[handler]]
type = "image"
origin = "goes18"
directory = "./goes18/{region:short|lower}/{channel:short|lower}/{time:%Y-%m-%d}"
filename = "GOES18_{region:short}_{channel:short}_{time:%Y%m%dT%H%M%SZ}"
format = "jpg"
json = false

  [[handler.map]]
  path = "/usr/share/goestools/ne/ne_50m_admin_0_countries_lakes.json"

  [[handler.map]]
  path = "/usr/share/goestools/ne/ne_50m_admin_1_states_provinces_lakes.json"


# GOES-16 ABI false color.
[[handler]]
type = "image"
origin = "goes16"
regions = [ "fd", "m1", "m2" ]
channels = [ "ch02", "ch13" ]
directory = "./goes16/{region:short|lower}/fc/{time:%Y-%m-%d}"
filename = "GOES16_{region:short}_FC_{time:%Y%m%dT%H%M%SZ}"
format = "jpg"
json = false

  [handler.remap.ch02]
  path = "/usr/share/goestools/wxstar/wxstar_goes16_ch02_curve.png"

  [handler.lut]
  path = "/usr/share/goestools/wxstar/wxstar_goes16_lut.png"

  [[handler.map]]
  path = "/usr/share/goestools/ne/ne_50m_admin_0_countries_lakes.json"

  [[handler.map]]
  path = "/usr/share/goestools/ne/ne_50m_admin_1_states_provinces_lakes.json"

# GOES-16 ABI RGB-enhanced
[[handler]]
type = "image"
origin = "goes16"
regions = [ "fd", "m1", "m2" ]
channels = [ "ch07", "ch08", "ch09", "ch13", "ch14", "ch15" ]
directory = "./goes16/{region:short|lower}/{channel:short|lower}_enhanced/{time:%Y-%m-%d}"
filename = "GOES16_{region:short}_{channel:short}_enhanced_{time:%Y%m%dT%H%M%SZ}"
format = "jpg"
json = false

  ## The following gradients are rough approximations of the 
  ## McIDAS RGB enhancements used by NOAA/NESDIS/STAR on their site..
  ##
  ## For more info:
  ##
  ##   https://www.star.nesdis.noaa.gov/GOES/GOES16_FullDisk.php 
  ##   http://cimss.ssec.wisc.edu/goes/visit/water_vapor_enhancement.html
  ##   http://cimss.ssec.wisc.edu/goes/visit/enhanced_v_enhancements.html

  ## Shortwave IR (Channel 7)
  [handler.gradient.ch07]
  points = [
    { units = 400, color = "#000000" },
    { units = 250, color = "#b9b9b9" },
    { units = 249.999, color = "#00ffff" },
    { units = 240, color = "#000080" },
    { units = 230, color = "#00ff00" },
    { units = 220, color = "#ffff00" },
    { units = 210, color = "#ff0000" },
    { units = 200, color = "#000000" },
    { units = 190, color = "#ffffff" }
  ]

  ## Water Vapor (Channels 8 and 9)
  [handler.gradient.ch08]
  points = [
    { units = 276, color = "#000000" },
    { units = 275.9, color = "#ff0000" },
    { units = 258, color = "#ffff00" },
    { units = 250, color = "#000070" },
    { units = 233, color = "#ffffff" },
    { units = 195, color = "#408020" },
    { units = 178, color = "#00ffff" }
  ]
  [handler.gradient.ch09]
  points = [
    { units = 276, color = "#000000" },
    { units = 275.9, color = "#ff0000" },
    { units = 258, color = "#ffff00" },
    { units = 250, color = "#000070" },
    { units = 233, color = "#ffffff" },
    { units = 195, color = "#408020" },
    { units = 178, color = "#00ffff" }
  ]

  ## Longwave IR (Channels 13, 14, and 15)
  [handler.gradient.ch13]
  points = [
    { units = 333, color = "#000000" },
    { units = 238, color = "#b9b9b9" },
    { units = 237.999, color = "#00ffff" },
    { units = 228, color = "#000080" },
    { units = 218, color = "#00ff00" },
    { units = 208, color = "#ffff00" },
    { units = 198, color = "#ff0000" },
    { units = 188, color = "#000000" },
    { units = 178, color = "#ffffff" }
  ]
  [handler.gradient.ch14]
  points = [
    { units = 333, color = "#000000" },
    { units = 238, color = "#b9b9b9" },
    { units = 237.999, color = "#00ffff" },
    { units = 228, color = "#000080" },
    { units = 218, color = "#00ff00" },
    { units = 208, color = "#ffff00" },
    { units = 198, color = "#ff0000" },
    { units = 188, color = "#000000" },
    { units = 178, color = "#ffffff" }
  ]
  [handler.gradient.ch15]
  points = [
    { units = 333, color = "#000000" },
    { units = 238, color = "#b9b9b9" },
    { units = 237.999, color = "#00ffff" },
    { units = 228, color = "#000080" },
    { units = 218, color = "#00ff00" },
    { units = 208, color = "#ffff00" },
    { units = 198, color = "#ff0000" },
    { units = 188, color = "#000000" },
    { units = 178, color = "#ffffff" }
  ]

  [[handler.map]]
  path = "/usr/share/goestools/ne/ne_50m_admin_0_countries_lakes.json"

  [[handler.map]]
  path = "/usr/share/goestools/ne/ne_50m_admin_1_states_provinces_lakes.json"




# Images relayed from Himawari-9 After Dec 13th 2022. 
[[handler]] 
type = "image" 
origin = "himawari8" 
directory = "./himawari9/{region:short|lower}/{time:%Y-%m-%d}" 
filename = "Himawari9_{region:short}_{channel:short}_{time:%Y%m%dT%H%M%SZ}" 
format = "jpg" 
json = false 

[[handler.map]] 
path = "/usr/share/goestools/ne/ne_50m_admin_0_countries_lakes.json" 

[[handler.map]] 
path = "/usr/share/goestools/ne/ne_50m_admin_1_states_provinces_lakes.json"


# NWS text (weather reports).
[[handler]]
type = "text"
origin = "nws"
directory = "./nws/{time:%Y-%m-%d}"
filename = "{time:%Y%m%dT%H%M%SZ}_{awips:nnn}{awips:xxx}"
json = false

# NWS images.
[[handler]]
type = "image"
origin = "nws"
directory = "./nws/{time:%Y-%m-%d}"
filename = "{time:%Y%m%dT%H%M%SZ}_{filename}"
format = "png"
json = false

# Miscellaneous text.
[[handler]]
type = "text"
origin = "other"
directory = "./text/{time:%Y-%m-%d}"
filename = "{time:%Y%m%dT%H%M%SZ}_{filename}"
json = false


################
##  GOES-18 ####
################
# Store all original GOES-18 products.
[[handler]]
type = "image"
origin = "goes18"
directory = "./goes18/{region:short|lower}/{channel:short|lower}/{time:%Y-%m-%d}"
filename = "GOES18_{region:short}_{channel:short}_{time:%Y%m%dT%H%M%SZ}"
format = "jpg"
json = false

  [[handler.map]]
  path = "/usr/share/goestools/ne/ne_50m_admin_0_countries_lakes.json"

  [[handler.map]]
  path = "/usr/share/goestools/ne/ne_50m_admin_1_states_provinces_lakes.json"
  
# GOES-18 ABI false color.
[[handler]]
type = "image"
origin = "goes18"
regions = [ "fd", "m1", "m2" ]
channels = [ "ch02", "ch13" ]
directory = "./goes18/{region:short|lower}/fc/{time:%Y-%m-%d}"
filename = "GOES18_{region:short}_FC_{time:%Y%m%dT%H%M%SZ}"
format = "jpg"
json = false

  # This reuses the GOES-16 contrast curve assuming it is identical
  [handler.remap.ch02]
  path = "/usr/share/goestools/wxstar/wxstar_goes16_ch02_curve.png"

  # This reuses the GOES-16 LUT assuming it is identical
  [handler.lut]
  path = "/usr/share/goestools/wxstar/wxstar_goes16_lut.png"

  [[handler.map]]
  path = "/usr/share/goestools/ne/ne_50m_admin_0_countries_lakes.json"

  [[handler.map]]
  path = "/usr/share/goestools/ne/ne_50m_admin_1_states_provinces_lakes.json"

# GOES-18 ABI RGB-enhanced
[[handler]]
type = "image"
origin = "goes18"
regions = [ "fd", "m1", "m2" ]
channels = [ "ch07", "ch08", "ch09", "ch13", "ch14", "ch15" ]
directory = "./goes18/{region:short|lower}/{channel:short|lower}_enhanced/{time:%Y-%m-%d}"
filename = "GOES18_{region:short}_{channel:short}_enhanced_{time:%Y%m%dT%H%M%SZ}"
format = "jpg"
json = false

  ## The following gradients are rough approximations of the 
  ## McIDAS RGB enhancements used by NOAA/NESDIS/STAR on their site..
  ##
  ## For more info:
  ##
  ##   https://www.star.nesdis.noaa.gov/GOES/GOES16_FullDisk.php 
  ##   http://cimss.ssec.wisc.edu/goes/visit/water_vapor_enhancement.html
  ##   http://cimss.ssec.wisc.edu/goes/visit/enhanced_v_enhancements.html

  ## Shortwave IR (Channel 7)
  [handler.gradient.ch07]
  points = [
    { units = 400, color = "#000000" },
    { units = 250, color = "#b9b9b9" },
    { units = 249.999, color = "#00ffff" },
    { units = 240, color = "#000080" },
    { units = 230, color = "#00ff00" },
    { units = 220, color = "#ffff00" },
    { units = 210, color = "#ff0000" },
    { units = 200, color = "#000000" },
    { units = 190, color = "#ffffff" }
  ]

  ## Water Vapor (Channels 8 and 9)
  [handler.gradient.ch08]
  points = [
    { units = 276, color = "#000000" },
    { units = 275.9, color = "#ff0000" },
    { units = 258, color = "#ffff00" },
    { units = 250, color = "#000070" },
    { units = 233, color = "#ffffff" },
    { units = 195, color = "#408020" },
    { units = 178, color = "#00ffff" }
  ]
  [handler.gradient.ch09]
  points = [
    { units = 276, color = "#000000" },
    { units = 275.9, color = "#ff0000" },
    { units = 258, color = "#ffff00" },
    { units = 250, color = "#000070" },
    { units = 233, color = "#ffffff" },
    { units = 195, color = "#408020" },
    { units = 178, color = "#00ffff" }
  ]

  ## Longwave IR (Channels 13, 14, and 15)
  [handler.gradient.ch13]
  points = [
    { units = 333, color = "#000000" },
    { units = 238, color = "#b9b9b9" },
    { units = 237.999, color = "#00ffff" },
    { units = 228, color = "#000080" },
    { units = 218, color = "#00ff00" },
    { units = 208, color = "#ffff00" },
    { units = 198, color = "#ff0000" },
    { units = 188, color = "#000000" },
    { units = 178, color = "#ffffff" }
  ]
  [handler.gradient.ch14]
  points = [
    { units = 333, color = "#000000" },
    { units = 238, color = "#b9b9b9" },
    { units = 237.999, color = "#00ffff" },
    { units = 228, color = "#000080" },
    { units = 218, color = "#00ff00" },
    { units = 208, color = "#ffff00" },
    { units = 198, color = "#ff0000" },
    { units = 188, color = "#000000" },
    { units = 178, color = "#ffffff" }
  ]
  [handler.gradient.ch15]
  points = [
    { units = 333, color = "#000000" },
    { units = 238, color = "#b9b9b9" },
    { units = 237.999, color = "#00ffff" },
    { units = 228, color = "#000080" },
    { units = 218, color = "#00ff00" },
    { units = 208, color = "#ffff00" },
    { units = 198, color = "#ff0000" },
    { units = 188, color = "#000000" },
    { units = 178, color = "#ffffff" }
  ]

  [[handler.map]]
  path = "/usr/share/goestools/ne/ne_50m_admin_0_countries_lakes.json"

  [[handler.map]]
  path = "/usr/share/goestools/ne/ne_50m_admin_1_states_provinces_lakes.json"


################
##  GOES-19 ####
################
# Store all original GOES-19 products.
[[handler]]
type = "image"
origin = "goes19"
directory = "./goes19/{region:short|lower}/{channel:short|lower}/{time:%Y-%m-%d}"
filename = "GOES19_{region:short}_{channel:short}_{time:%Y%m%dT%H%M%SZ}"
format = "jpg"
json = false

  [[handler.map]]
  path = "/usr/share/goestools/ne/ne_50m_admin_0_countries_lakes.json"

  [[handler.map]]
  path = "/usr/share/goestools/ne/ne_50m_admin_1_states_provinces_lakes.json"
  
# GOES-19 ABI false color.
[[handler]]
type = "image"
origin = "goes19"
regions = [ "fd", "m1", "m2" ]
channels = [ "ch02", "ch13" ]
directory = "./goes19/{region:short|lower}/fc/{time:%Y-%m-%d}"
filename = "GOES19_{region:short}_FC_{time:%Y%m%dT%H%M%SZ}"
format = "jpg"
json = false

  # This reuses the GOES-16 contrast curve assuming it is identical
  [handler.remap.ch02]
  path = "/usr/share/goestools/wxstar/wxstar_goes16_ch02_curve.png"

  # This reuses the GOES-16 LUT assuming it is identical
  [handler.lut]
  path = "/usr/share/goestools/wxstar/wxstar_goes16_lut.png"

  [[handler.map]]
  path = "/usr/share/goestools/ne/ne_50m_admin_0_countries_lakes.json"

  [[handler.map]]
  path = "/usr/share/goestools/ne/ne_50m_admin_1_states_provinces_lakes.json"

# GOES-19 ABI RGB-enhanced
[[handler]]
type = "image"
origin = "goes19"
regions = [ "fd", "m1", "m2" ]
channels = [ "ch07", "ch08", "ch09", "ch13", "ch14", "ch15" ]
directory = "./goes19/{region:short|lower}/{channel:short|lower}_enhanced/{time:%Y-%m-%d}"
filename = "GOES19_{region:short}_{channel:short}_enhanced_{time:%Y%m%dT%H%M%SZ}"
format = "jpg"
json = false

  ## The following gradients are rough approximations of the 
  ## McIDAS RGB enhancements used by NOAA/NESDIS/STAR on their site..
  ##
  ## For more info:
  ##
  ##   https://www.star.nesdis.noaa.gov/GOES/GOES16_FullDisk.php 
  ##   http://cimss.ssec.wisc.edu/goes/visit/water_vapor_enhancement.html
  ##   http://cimss.ssec.wisc.edu/goes/visit/enhanced_v_enhancements.html

  ## Shortwave IR (Channel 7)
  [handler.gradient.ch07]
  points = [
    { units = 400, color = "#000000" },
    { units = 250, color = "#b9b9b9" },
    { units = 249.999, color = "#00ffff" },
    { units = 240, color = "#000080" },
    { units = 230, color = "#00ff00" },
    { units = 220, color = "#ffff00" },
    { units = 210, color = "#ff0000" },
    { units = 200, color = "#000000" },
    { units = 190, color = "#ffffff" }
  ]

  ## Water Vapor (Channels 8 and 9)
  [handler.gradient.ch08]
  points = [
    { units = 276, color = "#000000" },
    { units = 275.9, color = "#ff0000" },
    { units = 258, color = "#ffff00" },
    { units = 250, color = "#000070" },
    { units = 233, color = "#ffffff" },
    { units = 195, color = "#408020" },
    { units = 178, color = "#00ffff" }
  ]
  [handler.gradient.ch09]
  points = [
    { units = 276, color = "#000000" },
    { units = 275.9, color = "#ff0000" },
    { units = 258, color = "#ffff00" },
    { units = 250, color = "#000070" },
    { units = 233, color = "#ffffff" },
    { units = 195, color = "#408020" },
    { units = 178, color = "#00ffff" }
  ]

  ## Longwave IR (Channels 13, 14, and 15)
  [handler.gradient.ch13]
  points = [
    { units = 333, color = "#000000" },
    { units = 238, color = "#b9b9b9" },
    { units = 237.999, color = "#00ffff" },
    { units = 228, color = "#000080" },
    { units = 218, color = "#00ff00" },
    { units = 208, color = "#ffff00" },
    { units = 198, color = "#ff0000" },
    { units = 188, color = "#000000" },
    { units = 178, color = "#ffffff" }
  ]
  [handler.gradient.ch14]
  points = [
    { units = 333, color = "#000000" },
    { units = 238, color = "#b9b9b9" },
    { units = 237.999, color = "#00ffff" },
    { units = 228, color = "#000080" },
    { units = 218, color = "#00ff00" },
    { units = 208, color = "#ffff00" },
    { units = 198, color = "#ff0000" },
    { units = 188, color = "#000000" },
    { units = 178, color = "#ffffff" }
  ]
  [handler.gradient.ch15]
  points = [
    { units = 333, color = "#000000" },
    { units = 238, color = "#b9b9b9" },
    { units = 237.999, color = "#00ffff" },
    { units = 228, color = "#000080" },
    { units = 218, color = "#00ff00" },
    { units = 208, color = "#ffff00" },
    { units = 198, color = "#ff0000" },
    { units = 188, color = "#000000" },
    { units = 178, color = "#ffffff" }
  ]

  [[handler.map]]
  path = "/usr/share/goestools/ne/ne_50m_admin_0_countries_lakes.json"

  [[handler.map]]
  path = "/usr/share/goestools/ne/ne_50m_admin_1_states_provinces_lakes.json"