This project is a set of functions for calculating the Canadian Forest Fire Weather Index (FWI), a Canadian Forest Service system to compute codes for fire behavior and emissions from weather. The FWI is described in detail in Van Wagner 1987. It also includes equations for computing % moisture content from the Duff Moisture Code (DMC) and a batch csv calculator for FWI. The README file that comes with the source covers installation and usage examples. A sample csv file is also provided. The FWI functions were directly translated from the Southeast Asia Fire Danger Rating System Project Excel Plugin. The DMC to % moisture functions are from Lawson et al 1997, who followed Van Wagner 1987 for DMC conversion.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| image |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| [{"ID":"thsOfugG","Name":"device_0","Active":false,"Geometry":{"Type":"Point","Coordinates":[-3.1002761187152714,-44.73816434283549]},"Share":"https://stlk.it/thsOfugG","Date":"2019-06-18T22:15:37+02:00","Temperature":8.11,"Battery":0.31},{"ID":"HmAjscDv","Name":"device_1","Active":true,"Geometry":{"Type":"Point","Coordinates":[-11.039520349683386,-79.53915383342887]},"Share":"https://stlk.it/HmAjscDv","Date":"2019-05-28T18:05:12+02:00","Temperature":34.32,"Battery":0.76},{"ID":"gSKmTTcx","Name":"device_2","Active":true,"Geometry":{"Type":"Point","Coordinates":[1.9862382370439349,102.25265679798002]},"Share":"https://stlk.it/gSKmTTcx","Date":"2019-02-19T00:24:43+01:00","Temperature":13.04,"Battery":0.01},{"ID":"YYZDXONV","Name":"device_3","Active":false,"Geometry":{"Type":"Point","Coordinates":[21.983652824877353,-49.18198206602062]},"Share":"https://stlk.it/YYZDXONV","Date":"2019-04-30T09:44:04+02:00","Temperature":28.38,"Battery":0.24},{"ID":"PObIbcBW","Name":"device_4","Active":false,"Geometry":{"Type":"Po |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| """ | |
| A bare bones examples of optimizing a black-box function (f) using | |
| Natural Evolution Strategies (NES), where the parameter distribution is a | |
| gaussian of fixed standard deviation. | |
| """ | |
| import numpy as np | |
| np.random.seed(0) | |
| # the function we want to optimize |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env bash | |
| # This script prints out all of your Redis keys and their size in a human readable format | |
| # Copyright 2013 Brent O'Connor | |
| # License: http://www.apache.org/licenses/LICENSE-2.0 | |
| human_size() { | |
| awk -v sum="$1" ' BEGIN {hum[1024^3]="Gb"; hum[1024^2]="Mb"; hum[1024]="Kb"; for (x=1024^3; x>=1024; x/=1024) { if (sum>=x) { printf "%.2f %s\n",sum/x,hum[x]; break; } } if (sum<1024) print "1kb"; } ' | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #! /usr/bin/env python | |
| import redis | |
| import random | |
| import pylibmc | |
| import sys | |
| r = redis.Redis(host = 'localhost', port = 6389) | |
| mc = pylibmc.Client(['localhost:11222']) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| black==19.3b0 | |
| pylint==2.3.1 | |
| ipython==7.5.0 | |
| notebook==5.7.8 | |
| jupyter==1.0.0 | |
| PyQt5==5.12.2 | |
| dask==1.2.2 | |
| Cython==0.29.7 | |
| numpy==1.16.3 | |
| pandas==0.24.2 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| base_url = "https://ssl.smn.gob.ar/dpd/descarga_opendata.php?file=" | |
| first_date = "20171126" | |
| """ | |
| Datos horarios | |
| Dato meteorológico de todas las estaciones de superficie del país | |
| Datos de temperatura, presión, viento y humedad de las estaciones meteorológicas de todo el país. | |
| """ | |
| path_datos_horarios = "observaciones/datohorario{}.txt".format(date) |