firelab / windninja

A diagnostic wind model developed for use in wildland fire modeling.
https://weather.firelab.org/windninja/
Other
118 stars 44 forks source link

Read in list of domain average runs from FlamMap output #528

Open nwagenbrenner opened 2 months ago

nwagenbrenner commented 2 months ago

Request from Chuck:

Natalie, When a user does a FARSITE run in FlamMap using Wind Ninja FlamMap produces the two attached .xml files. Each one has the initialized input speed and direction for the domain average input run, whether Diurnal was used (file: _19.tif.aux.xml ) or not (_29.tif.aux.xml)

My idea is the user uses WindNinja in FlamMap for a FARSITE run, then they decide they want use the full on Mass & Momentum solver in the DT WN. What I is wondering, is could this file from FlamMap be used to at least fill in the Wind Input section of the run so they don’t have to hand type in 20 gridded wind? I know they would still need to load the Surface input (ideally the same landscape file they are using in FlamMap, and the select the Output Type they would want to have as well as the resolutions etc.

The other files that could be used would be the .XML files if the user saves the Source Grids from a FlamMap WN run as Tiff file. Then they get two files with similar information. This one FishCreek_WN_Dirunal Grids.xml shows it by Burn period Day and hour While this one is just a long list. FishCreek_WN_Dirunal Grids.tiff.aux.xml but with the same information.

Regardless you will see 40-bands, but its only 20 separate WN runs. the bands are Wind Speed and Wind Direction, but they go together as separate WN runs. For example Bands 1&2 are one run, Bands 3&4 are another. Not the easiest to Parse in and there may be other most likely easier ways to do this or a different file created in FlamMap that may make it easier.

Example xml format:

<PAMDataset>
<PAMRasterBand band="1">
<Description>Wind Speed</Description>
<UnitType>mph</UnitType>
<Metadata>
<MDI key="Air Temperature (F)">61</MDI>
<MDI key="Cloud Cover (%)">45</MDI>
<MDI key="InputDirection">190</MDI>
<MDI key="InputSpeed">15 </MDI>
<MDI key="InputSpeedUnits">mph</MDI>
<MDI key="RepresentationType">THEMATIC</MDI>
<MDI key="Time">2024-08-25T14:00:00</MDI>
<MDI key="UnitOfMeasure">mph</MDI>
<MDI key="Use Diurnal">Yes</MDI>
</Metadata>
</PAMRasterBand>
<PAMRasterBand band="2">
<Description>Wind Direction</Description>
<UnitType>degrees</UnitType>
<Metadata>
<MDI key="Air Temperature (F)">61</MDI>
<MDI key="Cloud Cover (%)">45</MDI>
<MDI key="InputDirection">190</MDI>
<MDI key="InputSpeed">15 </MDI>
<MDI key="InputSpeedUnits">mph</MDI>
<MDI key="RepresentationType">THEMATIC</MDI>
<MDI key="Time">2024-08-25T14:00:00</MDI>
<MDI key="UnitOfMeasure">degrees</MDI>
<MDI key="Use Diurnal">Yes</MDI>
</Metadata>
</PAMRasterBand>
<PAMRasterBand band="3">
<Description>Wind Speed</Description>
<UnitType>mph</UnitType>
<Metadata>
<MDI key="Air Temperature (F)">61</MDI>
<MDI key="Cloud Cover (%)">55</MDI>
<MDI key="InputDirection">210</MDI>
<MDI key="InputSpeed">14 </MDI>
<MDI key="InputSpeedUnits">mph</MDI>
<MDI key="RepresentationType">THEMATIC</MDI>
<MDI key="Time">2024-08-25T15:00:00</MDI>
<MDI key="UnitOfMeasure">mph</MDI>
<MDI key="Use Diurnal">Yes</MDI>
</Metadata>
</PAMRasterBand>
<PAMRasterBand band="1">
<Description>Wind Speed</Description>
<UnitType>mph</UnitType>
<Metadata>
<MDI key="InputDirection">190</MDI>
<MDI key="InputSpeed">15 </MDI>
<MDI key="InputSpeedUnits">mph</MDI>
<MDI key="RepresentationType">THEMATIC</MDI>
<MDI key="Time">2024-08-25T14:00:00</MDI>
<MDI key="UnitOfMeasure">mph</MDI>
<MDI key="Use Diurnal">No</MDI>
</Metadata>
</PAMRasterBand>
<PAMRasterBand band="2">
<Description>Wind Direction</Description>
<UnitType>degrees</UnitType>
<Metadata>
<MDI key="InputDirection">190</MDI>
<MDI key="InputSpeed">15 </MDI>
<MDI key="InputSpeedUnits">mph</MDI>
<MDI key="RepresentationType">THEMATIC</MDI>
<MDI key="Time">2024-08-25T14:00:00</MDI>
<MDI key="UnitOfMeasure">degrees</MDI>
<MDI key="Use Diurnal">No</MDI>
</Metadata>
</PAMRasterBand>
<PAMRasterBand band="3">
<Description>Wind Speed</Description>
<UnitType>mph</UnitType>
<Metadata>
<MDI key="InputDirection">210</MDI>
<MDI key="InputSpeed">14 </MDI>
<MDI key="InputSpeedUnits">mph</MDI>
<MDI key="RepresentationType">THEMATIC</MDI>
<MDI key="Time">2024-08-25T15:00:00</MDI>
<MDI key="UnitOfMeasure">mph</MDI>
<MDI key="Use Diurnal">No</MDI>
</Metadata>
</PAMRasterBand>
nwagenbrenner commented 2 months ago

Other comments from Chuck regarding FlamMap.

If had to prioritize my “Wishes” for WN DT for use in FlamMap, and we’ve talked about these in the past it would be

Stop producing the CLD.asc as part of the firebehavior files no longer needed in FlamMap WN Stop producing .ASC output and .prj files shift to strictly GeoTiff file formats. Change the atmosphere file (.ATM) format to what we currently use in FlamMap, see here: https://owfflammaphelp62.firenet.gov/FileTypes/Atmosphere_File.htm