bcgov / wps

Wildfire Predictive Services to support decision making in prevention, preparedness, response and recovery
Apache License 2.0
36 stars 6 forks source link

FBP Go: Add date selector #3576

Open conbrad opened 2 months ago

conbrad commented 2 months ago

Actual Behaviour

I have noticed a difference in the crown fraction burned calculation between FBP Go and the Red Book and Red App. Here’s an example using an FFMC of 95, a wind speed of 10, and BUI of 150. I had thought there would be some differences due to rounding between the red book and FBP Go, but that Red app and FBP Go would be the same. Red App is at 88%, similar to the Red Book, while FBP Go is 94% CFB.

I have a scenario in the S-390 where I ask them to estimate the time of day the fire may go from surface to intermittent crown, then to a continuous crown fire. Currently, Red App and the red book show no continuous crown fire, while FBP Go shows continuous crown fire during the peak of the burning period. They are all quite close, but I tested it with M4 30% and there is a 2% difference between FBP Go and Redapp.

Steps To Reproduce

  1. Input FFMC: 95, Wind Speed: 10, BUI: 150 into FBP Go and Red App
  2. Red App shows 88% CFB, FBP Go shows 94% CFB
  3. Red App and Red Book shows no continuous crown fire, while FBP Go shows continuous crown fire during the peak burning period.

Expected Behaviour

FBP Go should show a closer CFB value to Red App and Red book, and the same surface/IC/CC values for peak burning.

nealmcloughlin commented 2 months ago

Hi PSU team,

I had a look at an issue Eric recently reported regarding inconsistency in Crown Fraction Burned outputs between REDapp and the Redbook versus FBPGo. I’m happy to report that there is no bug or inconsistency. Let me explain how I determined this, and what you need to know about using FBPGo (or any other fire behaviour calculator).

FBPGo uses the ‘cffdrs’ package in R to perform fire behaviour calculations. I used the following script to replicate the REDapp example Eric provided in his email.

library(cffdrs)

input <- data.frame( FuelType="C-3", LAT=48.4502, LONG=-123.3435, FFMC=95, BUI=150, WS=10, WD=230, GS=0, Dj=as.integer(format(as.Date("2024-07-08"),"%j")), Aspect=0, CBH=8, CFL=1.15, Accel=0, hr=1, ELV=570 )

fbp(input, output = "All")

The output from the R console is a bit hard to read but matches the 88% Crown Fraction Burned value from REDapp and the Redbook (CFB = 0.8796533). This is how I determined there is not a bug in the FBP calculations implemented in FBPGo.

ID CFB CFC FD HFI RAZ ROS SFC TFC BE SF ISI FFMC FMC D0 RSO 1 1 0.8796533 1.011601 I 20113.42 50 13.13299 4.093461 5.105063 1.145805 1 14.3231 95 120 0 3.926994 CSI FROS BROS HROSt FROSt BROSt FCFB BCFB FFI BFI FTFC BTFC TI 1 4822.5 4.829589 1.120521 13.13299 4.829589 1.120521 0.1874654 0 6243.278 1376.043 4.309047 4.093461 3.44881 FTI BTI LB LBt WSV DH DB DF TROS TROSt TCFB TFI TTFC 1 32.78863 0 1.475644 1.475644 10 787.9793 67.23128 289.7753 11.96788 11.96788 0.8426692 18176.34 5.062531 TTI 1 3.956034

So why the difference in Eric’s FBPGo example you ask? There are a couple important details that influence Foliar Moisture Content (FMC) calculations that you must pay particular attention to for consistent outputs. FMC is an input into the Critical Surface Intensity equation which subsequently influences Crown Fraction Burned.

• Eric’s FBPGo example used different Lat/Long coordinates and a different elevation than his REDapp example. Differences in Lat/Long and elevation will result in differences in calculated FMC values if the your within the spring dip window. • That brings up the other important difference which is the date. Eric’s REDapp example used July 8 as the date which is outside of the spring dip window and resulted in an FMC of 120%. FBPGo does not provide an option to enter a date. It instead assumes you are performing a prediction for today. The test I performed in R allowed me to set the date to July 8, 2024.

If you perform a calculation in FBPGo and enter all the same inputs into REDapp for today’s date you should get near identical values to the first or second decimal place. Minor discrepancies have to do with differences in the programming languages. REDapp is programmed in Java, where as FBPGo is leveraging an R package. The key takeaway is that Lat/Long, elevation, and date all matter when performing FBP Calculations. A limitation of using the Redbook in fire behaviour training is that it does not expose FBANs to the influence of FMC. The Redbook assumes you are outside of the spring dip window and FMC is 120%.

Understanding that you are using FBPGo to perform retrospective calculations in training courses, there is an important user feature missing which is a date selector. I have added an FBPGo date selector to the Agile team’s backlog. The date selector will default to today’s date, but can otherwise be changed if need be to avoid these discrepancies. The date selector value is then converted to a Julian date (1 to 366) for input into the FBP calculations.