{ "info": { "author": "Michael Billmire", "author_email": "mgbillmi@mtu.edu", "bugtrack_url": null, "classifiers": [ "Development Status :: 3 - Alpha", "Intended Audience :: Developers", "Intended Audience :: Science/Research", "License :: OSI Approved :: BSD License", "Operating System :: OS Independent", "Programming Language :: Python", "Topic :: Scientific/Engineering :: Physics", "Topic :: Software Development :: Libraries :: Python Modules" ], "description": "==============\nPython-Consume\n==============\nPython-Consume is a Python package that is a port of Consume 3.0, a software \nprogram developed by the USFS that calculates consumption and emissions from \nwildland fires.\n\nConsume 3.0 was developed and designed originally in Java by US Forest \nService Fire and Environmental Research Applications (FERA) team.\n\nThis is a recoded version (2010) developed by Michigan Tech Research\nInstitute (MTRI) in consultation with FERA. This version was developed\nfor use in MTRI's Wildfire Emissions Information System (WFEIS) \n(wfeis.mtri.org), but was also designed to include more user-friendly\nshell-based analysis options.\n\nDuring the recoding process, several errors were identified in the original\nConsume 3.0 source code, but were fixed (via consultation with original\ndevelopers Roger Ottmar and Susan Prichard) for this version. For this reason,\nresults from this version will not always align with results from the official\nConsume 3.0 GUI version of the software. Notable errors include:\n\n1. incorrect calculation of 'duff' reduction (p. 182 in the Consume 3.0)\n2. a bug that interchanges 'squirrel midden' density and radius when FCCS\n values are loaded\n3. a typo that incorrectly calculates pm2.5 emissions from 'canopy'\n consumption (thus influencing total pm2.5 emissions values as well)\n\n*For users familiar with the original Consume 3.0 GUI software, see the \nnotes section below for functionality and operational differences between\nthis version and the original.*\n\nReferences:\n\n* CONSUME: http://www.fs.fed.us/pnw/fera/research/smoke/consume/index.shtml\n* FCCS: http://www.fs.fed.us/pnw/fera/fccs/\n* FERA: http://www.fs.fed.us/pnw/fera/F\n* MTRI: http://www.mtri.org\n\nRequirements:\n\n* Python 2.4 or above (free from http://www.python.org)\n* numpy package (free from http://np.scipy.org/)\n\nFor questions/comments, contact:\n\n* Michael G. Billmire mgbillmi@mtu.edu\n* Tyler A. Erickson taericks@mtu.edu\n\n------------\nDependencies\n------------\n* Python 2.4 or above \n* python-numpy (free from http://np.scipy.org/)\n\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\nNotes for users familiar with the original Consume 3.0 GUI software\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n\n* This version relies entirely on FCCS fuelbed data and does NOT use SAF/SRM\n cover type data except in the background for selecting the correct emissions\n factor groups to use from a link table provided by FERA.\n* *Heat release* output is coupled with consumption outputs.\n* Instead of selecting a specific ecoregion from Bailey's set, this version only\n requires the user to specify whether the fuelbed is located in *western*, \n *boreal*, or *southern* regions. See the original Consume 3.0 User's Manual\n to view which Bailey's ecoregions fit into these broader categories. \n\n------------\nInstallation\n------------\nPython-Consume can be installed from the Python Package Index, using either \neasy_install or pip:\n\n $ sudo easy_install python-consume\n\nor\n\n $ sudo pip install python-consume\n\nThe installation can be tested by running the following:\n\n $ nosetests -s --with-coverage\n\n-------------------------------------------\nUsage\n-------------------------------------------\n\n(See next section for a complete, uninterrupted example...)\n\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\nGetting Started with the Fuel Consumption Object\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n\nOpen a Python shell program (e.g. IDLE, ipython, etc.).\nImport the module:\n\n>>> from consume import consume\n\nDeclare a Consume FuelConsumption object:\n\n>>> fc_obj = consume.FuelConsumption()\n\n\n*Note: if the .xml fuel loading database is located somewhere other than\nthe default location, user can specify this using the 'fccs_file' argument,\ne.g.:\nfc_obj = consume.FuelConsumption(fccs_file=\"C:/Documents/FCCSLoadings.xml\")*\n\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\nSETTING INPUT PARAMETERS\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n\nThere are a number of alternative options for setting input values:\n\n1. Start a program that will prompt the user for inputs:\n >>> fc_obj.prompt_for_inputs()\n\n2. Load inputs from a pre-formatted csv file (see example file:\n \"consume_inputs_example.csv\" for correct formatting):\n \n >>> fc_obj.load_scenario(\"myscenario.csv\")\n \n OR to load, calculate outputs, and store outputs at once, use the\n batch_process method:\n \n >>> fc_obj.batch_process(\"myscenario.csv\", \"myoutputs.csv\")\n\n3. Individually set/change input values manually:\n \n >>> fc_obj.burn_type = <'natural' or 'activity'>\n >>> fc_obj.fuelbed_fccs_ids = [FCCSID#1,FCCSID#2,...]\n >>> fc_obj.fuelbed_area_acres = [AREA#1,AREA#2,...]\n >>> fc_obj.fuelbed_ecoregion = [ECOREGION#1, ECOREGION#2,...]\n >>> fc_obj.fuel_moisture_1000hr_pct = [1000hrFM#1, 1000hrFM#2,...]\n >>> fc_obj.fuel_moisture_duff_pct = [DuffFM#1, DuffFM#2, ...]\n >>> fc_obj.canopy_consumption_pct = [PctCan#1, PctCan#2,...]\n >>> fc_obj.shrub_blackened_pct = [PercentShrub#1, PercentShrub#2,...]\n\n inputs specific to 'activity' burns:\n \n >>> fc_obj.fuel_moisture_10hr_pct = [10HourFM#1, 10HourFM#2, ...]\n >>> fc_obj.slope = [Slope#1, Slope#2, ...]\n >>> fc_obj.windspeed = [Windspeed#1, Windspeed#2, ...]\n >>> fc_obj.fm_type = <'MEAS-Th', 'ADJ-Th', or 'NFDRS-Th'>\n >>> fc_obj.days_since_rain = [Days#1, Days#2, ...]\n >>> fc_obj.lengthOfIgnition = [Length#1, Length#2, ...]\n\n\n *Note: When setting input values, the user can also select a SINGLE \n value (instead of a list) for any environment variable that will \n apply to the entire scenario.\n These environment variables include the following:\n ecoregion, fuel_moisture_1000hr_pct, fuel_moisture_duff_pct, \n canopy_consumption_pct, shrub_blackened_pct, slope, windpseed, \n fm_type, days_since_rain, lengthOfIgnition*\n\nDescription of the input parameters:\n\nburn_type\n Use this variable to select 'natural' burn equations or \n 'activity' (i.e. prescribed) burn equations. Note that\n 'activity' burns require 6 additional input parameters:\n 10hr fuel moisture, slope, windpseed, fuel moisture type,\n days since significant rainfall, and length of ignition.\n \nfuelbed_fccs_ids\n a list of Fuel Characteristic Classification System (FCCS)\n (http://www.fs.fed.us/pnw/fera/fccs/index.shtml) fuelbed ID\n numbers (1-291). Use the .FCCS.browse() method to load a list\n of all FCCS ID#'s and their associated site names. Use \n .FCCS.info(id#) to get a site description of the\n specified FCCD ID number. To get a complete listing of fuel\n loadings for an FCCS fuelbed, use: \n .FCCS.info(id#, detail=True)\n\nfuelbed_area_acres\n a list (or single number to be used for all fuelbeds) of\n numbers in acres that represents area for the corresponding\n FCCS fuelbed ID listed in the 'fuelbeds_fccs_ids' variable.\n\nfuelbed_ecoregion\n a list (or single region to be used for all fuelbeds) of\n ecoregions ('western', 'southern', or 'boreal') that\n represent the ecoregion for the corresponding FCCS fuelbed ID\n listed in the 'fuelbeds_fccs_ids' variable. Regions within the\n US that correspond to each broad regional description can be\n found in the official Consume 3.0 User's Guide, p. 60. Further\n info on Bailey's ecoregions can be found here:\n www.eoearth.org/article/Ecoregions_of_the_United_States_(Bailey)\n Default is 'western'\n\nfuel_moisture_1000hr_pct\n 1000-hr fuel moisture in the form of a number or list of\n numbers ranging from 0-100 representing a percentage.\n Default is 50%\n\nfuel_moisture_10hr_pct\n \n 10-hr fuel moisture in the form of a number or list of\n numbers ranging from 0-100 representing a percentage.\n Default is 50%\n\nfuel_moisture_duff_pct\n Duff fuel moisture. A number or list of numbers ranging from\n 0-100 representing a percentage.\n Default is 50%.\n\ncanopy_consumption_pct\n Percent canopy consumed. A number or list of numbers ranging\n from 0-100 representing a percentage. Set to '-1' to\n use an FCCS-fuelbed dependent precalculated canopy consumption\n percentage based on crown fire initiation potential, crown to\n crown transmissivity, and crown fire spreading potential.\n (note: auto-calc is not available for FCCS ID's 401-456)\n Default is -1\n\nshrub_blackened_pct\n Percent of shrub that has been blackened. A number or list\n of numbers ranging from 0-100 representing a percentage.\n Default is 50%\n\nslope\n \n Percent slope of a fuelbed unit. Used in predicting 100-hr\n (1-3\" diameter) fuel consumption in 'activity' fuelbeds.\n Valid values: a number or list of numbers ranging from 0-100\n representing a percentage.\n Default is 5%\n\nwindspeed\n \n Mid-flame wind speed (mph) during the burn. Maximum is 35 mph.\n Used in predicting 100-hr (1-3\" diameter) fuel consumption in \n 'activity' fuelbeds.\n Default is 5 mph\n\nfm_type\n \n Source of 1000-hr fuel moisture data.\n \n * \"Meas-Th\" (default) : measured directly\n * \"NFDRS-Th\" : calculated from NFDRS\n * \"ADJ-Th\" : adjusted for PNW conifer types\n \n Note: 1000-hr fuel moisture is NOT calculated by Consume, \n i.e. user must derive 1000-hr fuel moisture & simply select\n the method used.\n\ndays_since_rain\n \n Number of days since significant rainfall. According to the\n Consume 3.0 User's Guide, \"Significant rainfall is one-quarter\n inch in a 48-hour period.\" Used to predict duff consumption\n in 'activity' fuelbeds.\n\nlengthOfIgnition\n \n The amount of time (minutes) it will take to ignite the area\n to be burned. Used to determine if a fire will be of high \n intensity, which affects diameter reduction of large woody\n fuels in 'activity' fuelbeds.\n\nThe user can also optionally set alternate output units. Use the\nlist_valid_units() method to view output unit options.\nDefault fuel consumption units are tons/acre ('tons_ac').\n\n>>> consume.list_valid_units()\n\nOutput::\n\n ['lbs',\n 'lbs_ac',\n 'tons',\n 'tons_ac',\n 'kg',\n 'kg_m^2',\n 'kg_ha',\n 'kg_km^2'\n 'tonnes',\n 'tonnes_ha',\n 'tonnes_km^2']\n\n\n>>> fc_obj.output_units = 'lbs'\n\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\nCUSTOMIZING FUEL LOADINGS\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n\nFuel loadings are automatically imported from the FCCS database based on the\nFCCS fuelbed ID#s selected by the user. If desired, the user can also \ncustomize FCCS fuel loadings by setting the '.customized_fuel_loadings' variable\nto a list of 3 value lists in this format:\n[fuelbed index number {interger}, fuel stratum {string}, loading value {number}]\n\ne.g.:\n\n>>> fc_obj.customized_fuel_loadings = [[1, 'overstory', 4.5],[2, 'shrub_prim', 5]]\n\nThe above command will change the canopy 'overstory' loading in the first ('1')\nfuelbed to 4.5 (tons/acre) and will change the 'shrub_prim' (primary shrub\nloading) in the second ('2') fuelbed to 5 tons/acre. To view all valid stratum\nnames and units, use the fc_obj.FCCS.list_fuel_loading_names() method.\n\n\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\nOUTPUTS\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n\nConsumption outputs can be accessed by calling the .results(), .report(), or\n.batch_process() methods. Calling any of these methods will trigger the \ncalculation of all fuel consumption equation and will return the results in \na variety of different formats:\n\n\n>>> fc_obj.results()\n\n... generates & prints a python DICTIONARY of consumption\nresults by fuel category (major and minor categories)\nSee complete example below to see how individual\ndata categories can be accessed from this dictionary.\n\n>>> fc_obj.report(csv=\"\")\n\n...prints a TABULAR REPORT of consumption results for\nthe major fuel categories (similar to the \"Fuel\nConsumption by Combustion Stage\" report produced by the\nofficial Consume 3.0 GUI program). To export a version \nof this report as a CSV FILE, use the 'csv' argument to \nspecify a file name, e.g.:\n>>> fc_obj.report(csv = \"consumption_report.csv\")\n\n>>> fc_obj.batch_process(csvin=\"\", csvout=\"\")\n\n...similar to the .report() method, although requires an\ninput csv file and will export results to the specified\nCSV output.\n\n\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\nOTHER USEFUL METHODS\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n\n>>> consume.list_valid_units() \n\n...displays a list of valid output unit options\n\n>>> consume.list_valid_consumption_strata()\n\n...displays a list of valid consumption strata group names\n\n>>> fc_obj.list_variable_names()\n\n...displays a list of the variable names used for each input parameter\n\n>>> fc_obj.FCCS.browse()\n\n...loads a list of all FCCS fuelbed ID numbers and their site names\n\n>>> fc_obj.FCCS.info(#)\n\n...provides site description of the FCCS fuelbed with the specified ID number. \nSet detail=True to print out detailed fuel loading information\n\n>>> fc_obj.FCCS.get_canopy_pct(#)\n\n...displays estimated canopy consumption percent as calculated by MTRI for the \nspecified FCCS ID number. This is the value that will be used if \ncanopy_consumption_pct is set to -1.\n\n>>> fc_obj.load_example()\n\n...loads an example scenario with 2 Fuelbeds\n\n>>> fc_obj.reset_inputs_and_outputs()\n\n...clears input and output parameters\n\n>>> fc_obj.display_inputs()\n\n...displays a list of the input parameters.\nUseful for checking that scenario parameters were set correctly\n\n\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\nWorking with the EMISSIONS Object\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n\nFor emissions data, declare a Consume Emissions object by nesting in the\nFuelConsumption object we were working on above as the only required argument.\n\n>>> e_obj = consume.Emissions(fc_obj)\n\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\nSETTING INPUT PARAMETERS\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n\nInput parameters for emissions calculations are much easier to set than those\nfor FuelConsumption, as they are ALL ultimately automatically derived from the\nparameters set within the nested FuelConsumption object.\nThe input parameters required for the emissions calculations are as follows:\n\n* FUEL CONSUMPTION (tons/ac) & the scenario of corresponding FCCS ID#s,\n AREAS, and ECOREGIONS, all of which is derived from the FuelConsumption\n object specified in the Emissions object declaration we just did\n\n* EMISSIONS FACTOR GROUP ('efg'), which specifies the appropriate set of\n emissions factors (lbs/tons consumed for each of 7 emissions species) \n to use for the scenario. This is automatically selected based on the \n FCCS fuelbeds in the consumption scenario, but the user can override\n the auto-select process if desired as described below.\n\nAs with the FuelConsumption object, the user can also optionally set alternate \noutput units for the Emissions object. Use the consume.list_valid_units() method\nto view output unit options.\nDefault output units for emissions are lbs/ac.\n\n>>> e_obj.output_units = 'kg_ha'\n\nTo change the FuelConsumption units, simply modify the units of the FC object\nthat is nested within the Emissions object:\n\n>>> e_obj.FCobj.output_units = 'kg_ha'\n\n\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\nOUTPUTS\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n\nAs with the FuelConsumption object, Emissions outputs can be accessed by \ncalling the .results() or .report() methods. Calling either methods will trigger\nthe calculation of emissions and output results in a variety of different\nformats:\n\n>>> e_obj.results()\n\n...generates a python DICTIONARY similar to the one created\nby the FuelConsumption object, but with Emissions\nresults added (consumption data is also included).\nSee complete example below to see how specific\ndata categories can be accessed in this dictionary.\n\n>>> e_obj.report()\n\n...prints a TABULAR REPORT of emissions results for all\npollutants and combustion stages (similar to the\n\"Emissions by Combustion Stage\" report produced in \nthe official Consume 3.0 GUI program). To export\na version of this report as a CSV FILE, use the\n'csv' argument to specify a file name, e.g.:\n>>> e_obj.report(csv = \"emissions_report.csv\")\n\n\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\nOTHER USEFUL METHODS\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n\n>>> e_obj.display_inputs()\n\n...displays a list of the input parameters.\nUseful for checking that scenario\nparameters were set correctly\n\n>>> e_obj.efDB.browse()\n\n...displays a list of all emissions factor\ngroups and their associated fuel types\nand references\n\n>>> e_obj.efDB.info(#)\n\n...display detailed information about the\nspecified emissions factor group ID#\n(use the .browse() method above to view\nID#s). Includes the actual emissions\nfactor values.\n\nFor further help on specific methods or properties,\ntype \"help([CONSUME METHOD])\" within a python shell, e.g.:\n\n>>> help(fc_obj.FCCS.info)\n\nOutput::\n\n Help on method info in module consume_obj:\n \n info(self, fccs_id, detail=False) method of consume_obj.FCCSDB instance\n Display an FCCS fuelbed description.\n \n Prints fuel loading information on the fuelbed with the specified\n FCCS ID. Requires one argument: an integer refering to a specific FCCS\n ID. For a list of valid FCCS IDs, use the .browse() method.\"\n\n\n-------------------------------------------\nComplete Uninterrupted Example\n-------------------------------------------\n\nThe following example sets up a 'natural' burn scenario in which 100 acres FCCS \nfuelbed ID #1 (\"Black cottonwood - Douglas fir - Quaking aspen riparian forest\")\nand 200 acres of FCCS fuelbed ID #47 (\"Redwood - Tanoak forest\") are consumed.\n1000-hr and duff fuel moisture is set at 50% for fuelbed ID #1 and 40% for\nfuelbed ID #47. Canopy consumption and shrub percent black is set at 25% for\nboth fuelbeds.\n\n>>> from consume import consume\n>>> fc_obj = consume.FuelConsumption()\n>>> fc_obj.fuelbed_fccs_ids = [1, 47]\n>>> fc_obj.fuelbed_area_acres = [100, 200]\n>>> fc_obj.fuelbed_ecoregion = 'western'\n>>> fc_obj.fuel_moisture_1000hr_pct = [50, 40]\n>>> fc_obj.fuel_moisture_duff_pct = [50, 40]\n>>> fc_obj.canopy_consumption_pct = 25\n>>> fc_obj.shrub_blackened_pct = 25\n>>> fc_obj.output_units = 'kg_ha'\n>>> fc_obj.display_inputs()\n\nOutput::\n\n Current scenario parameters:\n \n Parameter Value(s)\n --------------------------------------------------------------\n Burn type natural\n FCCS fuelbeds (ID#) [1, 47]\n Fuelbed area (acres) [100, 200]\n Fuelbed ecoregion western\n Fuel moisture (1000-hr, %) [50, 40]\n Fuel moisture (duff, %) [50, 40]\n Canopy consumption (%) 25\n Shrub blackened (%) 25\n Output units kg_ha\n\n\n>>> fc_obj.report()\n\nOutput::\n\n FUEL CONSUMPTION\n Consumption units: kg/ha\n Heat release units: btu/ha\n Total area: 300 acres\n\n FCCS ID: 1\n Area: 100\n Ecoregion: western\n CATEGORY Flaming Smoldering Residual TOTAL\n canopy 1.25e+04 9.58e+02 1.51e+02 1.36e+04\n shrub 1.26e+03 6.97e+01 0.00e+00 1.33e+03\n nonwoody 3.95e+02 2.08e+01 0.00e+00 4.16e+02\n llm 2.32e+03 2.20e+02 0.00e+00 2.54e+03\n ground fuels 8.97e+02 1.51e+04 3.72e+04 5.32e+04\n woody fuels 9.71e+03 5.61e+03 8.81e+03 2.41e+04\n TOTAL: 2.70e+04 2.20e+04 4.61e+04 9.52e+04\n\n Heat release: 1.19e+08 9.70e+07 2.03e+08 4.20e+08\n\n\n FCCS ID: 47\n Area: 200\n Ecoregion: western\n CATEGORY Flaming Smoldering Residual TOTAL\n canopy 7.93e+03 2.48e+03 2.05e+03 1.25e+04\n shrub 3.87e+03 2.69e+02 0.00e+00 4.13e+03\n nonwoody 9.88e+02 5.20e+01 0.00e+00 1.04e+03\n llm 4.93e+03 5.41e+02 0.00e+00 5.47e+03\n ground fuels 3.59e+03 4.08e+04 6.98e+04 1.14e+05\n woody fuels 2.56e+04 2.06e+04 2.49e+04 7.11e+04\n TOTAL: 4.69e+04 6.47e+04 9.67e+04 2.08e+05\n\n Heat release: 2.07e+08 2.85e+08 4.27e+08 9.18e+08\n\n\n ALL FUELBEDS:\n\n Consumption: 4.03e+04 5.04e+04 7.99e+04 1.71e+05\n Heat release: 3.26e+08 3.82e+08 6.30e+08 1.34e+09\n\n\n\n>>> fc_obj.results()['consumption']['ground fuels']\n\nOutput::\n\n {'basal accumulations': {'flaming': array([-0., 0.]),\n 'residual': array([-0., 0.]),\n 'smoldering': array([-0., 0.]),\n 'total': array([-0., 0.])},\n 'duff, lower': {'flaming': array([ 0., 0.]),\n 'residual': array([ 35377.20573062, 62608.52081126]),\n 'smoldering': array([ 8844.30143266, 15652.13020281]),\n 'total': array([ 44221.50716328, 78260.65101407])},\n 'duff, upper': {'flaming': array([ 896.68092549, 3586.72370195]),\n 'residual': array([ 1793.36185097, 7173.4474039 ]),\n 'smoldering': array([ 6276.76647841, 25107.06591365]),\n 'total': array([ 8966.80925487, 35867.23701949])},\n 'squirrel middens': {'flaming': array([ 0., 0.]),\n 'residual': array([ 0., 0.]),\n 'smoldering': array([ 0., 0.]),\n 'total': array([ 0., 0.])}}\n\n\n>>> e_obj = consume.Emissions(fc_obj)\n>>> e_obj.display_inputs()\n\nOutput::\n\n CONSUMPTION\n\n Current scenario parameters:\n\n Parameter Value(s)\n --------------------------------------------------------------\n Burn type ['natural']\n FCCS fuelbeds (ID#) [1, 47]\n Fuelbed area (acres) [ 100. 200.]\n Fuelbed ecoregion ['western']\n Fuel moisture (1000-hr, %) [ 50. 40.]\n Fuel moisture (duff, %) [ 50. 40.]\n Canopy consumption (%) [ 25.]\n Shrub blackened (%) [ 25.]\n Output units ['kg_ha']\n\n EMISSIONS\n\n Current scenario parameters:\n\n Parameter Value(s)\n --------------------------------------------------------------\n\n>>> e_obj.report()\n\nOutput::\n\n EMISSIONS\n Units: lbs_ac\n\n FCCS ID: 1\n Area: 100 ac. (40.5 ha)\n Emissions factor group: 2\n SPECIES Flaming Smoldering Residual TOTAL\n pm 2.77e+02 3.73e+02 7.82e+02 1.43e+03\n pm10 1.69e+02 2.54e+02 5.33e+02 9.56e+02\n pm2.5 1.47e+02 2.30e+02 4.82e+02 8.58e+02\n co 1.11e+03 3.59e+03 7.53e+03 1.22e+04\n co2 4.09e+04 2.80e+04 5.87e+04 1.28e+05\n ch4 5.31e+01 1.92e+02 4.03e+02 6.49e+02\n nmhc 6.27e+01 1.37e+02 2.88e+02 4.88e+02\n\n FCCS ID: 47\n Area: 200 ac. (80.9 ha)\n Emissions factor group: 4\n SPECIES Flaming Smoldering Residual TOTAL\n pm 4.60e+02 9.69e+02 1.45e+03 2.88e+03\n pm10 2.45e+02 7.30e+02 1.09e+03 2.07e+03\n pm2.5 2.01e+02 6.81e+02 1.02e+03 1.90e+03\n co 1.11e+03 7.87e+03 1.18e+04 2.08e+04\n co2 7.24e+04 8.72e+04 1.30e+05 2.90e+05\n ch4 6.28e+01 5.08e+02 7.60e+02 1.33e+03\n nmhc 6.70e+01 3.81e+02 5.70e+02 1.02e+03\n\n ALL FUELBEDS:\n Units: lbs_ac\n Total area: 300 ac. (121.4 ha)\n pm 3.99e+02 7.70e+02 1.23e+03 2.40e+03\n pm10 9.45e+01 3.02e+01 2.14e+01 1.46e+02\n pm2.5 2.96e+01 3.08e+00 0.00e+00 3.27e+01\n co 7.81e+00 6.37e-01 0.00e+00 8.45e+00\n co2 4.02e+01 6.65e+00 0.00e+00 4.68e+01\n ch4 2.65e+01 4.93e+02 9.07e+02 1.43e+03\n nmhc 2.01e+02 2.37e+02 2.99e+02 7.36e+02\n\n\n>>> e_obj.results()['emissions']['co2']\n\nOutput::\n\n {'flaming': array([ 40877.14600611, 72354.16061005]),\n 'residual': array([ 58664.90328723, 130457.66209735]),\n 'smoldering': array([ 27980.07467362, 87193.41115534]),\n 'total': array([ 127522.12396695, 290005.23386274])}\n\n\n\n-------------------------------------------\nNavigating the .results() dictionaries\n-------------------------------------------\n\nThe table below depicts all categories included in the .results() dictionaries\nthat are produced from the FuelConsumption and Emissions objects. Note that the\nFuelConsumption .results() dictionary does NOT include emissions data while the\nEmissions .results() dictionary includes BOTH consumption and emissions data.\n\nThe FINAL index in the dictionary will be always be an integer that indicates\nthe fuelbed unit in the scenario. In the example above, a [0] would access \ndata for the first fuelbed (FCCS ID #1) and a [1] would access data for the \nsecond fuelbed (FCCS ID #47). Use Python's built-in 'sum()' function to\ncalculate total consumption/emissions across ALL fuelbeds.\n\n\n~~~~~~~~~~~~~\nExamples\n~~~~~~~~~~~~~\n\nTo access TOTAL consumption for the given scenario for each fuelbed unit:\n\n>>> fc_obj.results()['consumption']['summary']['total']['total']\n\nTo access TOTAL consumption for only the first fuelbed unit in the scenario:\n\n>>> fc_obj.results()['consumption']['summary']['total']['total'][0]\n\nTo access TOTAL consumption for the given scenario across ALL fuelbeds*:\n\n>>> sum(fc_obj.results()['consumption']['summary']['total']['total'])\n\nTo access consumption data for all canopy strata:\n\n>>> fc_obj.results()['consumption']['canopy']\n\nTo access TOTAL canopy consumption:\n\n>>> fc_obj.results()['consumption']['summary']['canopy']['total']\n\nTo access 'co2' emissions from all combustion stages:\n\n>>> e_obj.results()['emissions']['co2']\n\nTo access total 'co2' emissions for the given scenario across ALL fuelbeds*:\n\n>>> sum(e_obj.results()['emissions']['co2']['total'])\n\nTo view units that the emissions data are in:\n\n>>> e_obj.results()['parameters']['units_emissions']\n\n *Note: if outputs units are per-area units (i.e. tons/acre or kg/ha), these \n sum' functions will not provide an accurate representation of the overall\n consumption rate for the scenario.*\n\nOutput::\n\n Index 1 Index 2 Index 3 Index 4 Index 5 \n -----------------------------------------------------------------------------------------------------------------------------\n\n 'parameters' 'fuel moisture: 1000hr'\n 'fuel moisture duff'\n 'fuel moisture pct canopy consumed'\n 'fuel moisture pct shrub blackened'\n 'fuelbed area'\n 'fuelbed ecoregion'\n 'fuelbed fccs id'\n 'units consumption'\n 'units emissions'\n -----------------------------------------------------------------------------------------------------------------------------\n \n 'emissions' 'ch4' 'flaming','smoldering','residual', or 'total'\n 'co' 'flaming','smoldering','residual', or 'total'\n 'co2' 'flaming','smoldering','residual', or 'total'\n 'nmhc' 'flaming','smoldering','residual', or 'total'\n 'pm' 'flaming','smoldering','residual', or 'total'\n 'pm10' 'flaming','smoldering','residual', or 'total'\n 'pm25' 'flaming','smoldering','residual', or 'total'\n \n 'stratum' 'ch4' 'canopy' 'flaming','smoldering','residual', or 'total\n 'ground fuels' ''\n 'litter-lichen-moss' ''\n 'nonwoody' ''\n 'shrub' ''\n 'woody fuels' ''\n 'co' 'canopy' ''\n 'ground fuels' ''\n 'litter-lichen-moss' ''\n 'nonwoody' ''\n 'shrub' ''\n 'woody fuels' ''\n 'co2' .....etc.....\n \n\n -----------------------------------------------------------------------------------------------------------------------------\n \n 'heat release' 'flaming'\n 'smoldering'\n 'residual'\n 'total'\n\n -----------------------------------------------------------------------------------------------------------------------------\n\n 'consumption' 'summary' 'total' 'flaming','smoldering','residual', or 'total'\n 'canopy' 'flaming','smoldering','residual', or 'total'\n 'ground fuels' 'flaming','smoldering','residual', or 'total'\n 'litter-lichen-moss' 'flaming','smoldering','residual', or 'total'\n 'nonwoody' 'flaming','smoldering','residual', or 'total'\n 'shrub' 'flaming','smoldering','residual', or 'total'\n 'woody fuels' 'flaming','smoldering','residual', or 'total\n\n 'canopy' 'overstory' 'flaming','smoldering','residual', or 'total'\n 'midstory' 'flaming','smoldering','residual', or 'total'\n 'understory' 'flaming','smoldering','residual', or 'total'\n 'ladder fuels' 'flaming','smoldering','residual', or 'total'\n 'snags class 1 foliage' 'flaming','smoldering','residual', or 'total'\n 'snags class 1 non foliage' 'flaming','smoldering','residual', or 'total'\n 'snags class 1 wood' 'flaming','smoldering','residual', or 'total'\n 'snags class 2' 'flaming','smoldering','residual', or 'total'\n 'snags class 3' 'flaming','smoldering','residual', or 'total'\n \n 'ground fuels' 'duff upper' 'flaming','smoldering','residual', or 'total'\n 'duff lower' 'flaming','smoldering','residual', or 'total'\n 'basal accumulations' 'flaming','smoldering','residual', or 'total'\n 'squirrel middens' 'flaming','smoldering','residual', or 'total'\n\n 'litter-lichen-moss' 'litter' 'flaming','smoldering','residual', or 'total'\n 'lichen' 'flaming','smoldering','residual', or 'total'\n 'moss' 'flaming','smoldering','residual', or 'total'\n 'nonwoody' 'primary dead' 'flaming','smoldering','residual', or 'total'\n 'primary live' 'flaming','smoldering','residual', or 'total'\n 'secondary dead' 'flaming','smoldering','residual', or 'total'\n 'secondary live' 'flaming','smoldering','residual', or 'total'\n\n 'shrub' 'primary dead' 'flaming','smoldering','residual', or 'total'\n 'primary live' 'flaming','smoldering','residual', or 'total'\n 'secondary dead' 'flaming','smoldering','residual', or 'total'\n 'secondary live' 'flaming','smoldering','residual', or 'total'\n 'woody fuels' '1-hr fuels' 'flaming','smoldering','residual', or 'total'\n '10-hr fuels' 'flaming','smoldering','residual', or 'total'\n '100-hr fuels' 'flaming','smoldering','residual', or 'total'\n '1000-hr fuels sound' 'flaming','smoldering','residual', or 'total'\n '1000-hr fuels rotten' 'flaming','smoldering','residual', or 'total'\n '10000-hr fuels sound' 'flaming','smoldering','residual', or 'total'\n '10000-hr fuels rotten' 'flaming','smoldering','residual', or 'total'\n '10k+-hr fuels sound' 'flaming','smoldering','residual', or 'total'\n '10k+-hr fuels rotten' 'flaming','smoldering','residual', or 'total'\n 'stumps sound' 'flaming','smoldering','residual', or 'total'\n 'stumps rotten' 'flaming','smoldering','residual', or 'total'\n 'stumps lightered' 'flaming','smoldering','residual', or 'total'\n -----------------------------------------------------------------------------------------------------------------------------", "description_content_type": null, "docs_url": null, "download_url": "UNKNOWN", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "http://pypi.python.org/pypi/python-consume", "keywords": "kml", "license": "BSD", "maintainer": null, "maintainer_email": null, "name": "python-consume", "package_url": "https://pypi.org/project/python-consume/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/python-consume/", "project_urls": { "Download": "UNKNOWN", "Homepage": "http://pypi.python.org/pypi/python-consume" }, "release_url": "https://pypi.org/project/python-consume/0.1.1/", "requires_dist": null, "requires_python": null, "summary": "Python port of Consume, a software program developed by the USFS that calculates consumption and emissions from wildland fires", "version": "0.1.1" }, "last_serial": 797886, "releases": { "0.1.0": [ { "comment_text": "", "digests": { "md5": "bfcead3454d8eb7a7add80c12dcf2cf9", "sha256": "3b4ecff9d09717636f1ece1086b58dce8b52128e8240b469097a519b525d59d2" }, "downloads": -1, "filename": "python-consume-0.1.0.tar.gz", "has_sig": false, "md5_digest": "bfcead3454d8eb7a7add80c12dcf2cf9", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 144348, "upload_time": "2011-03-03T22:10:20", "url": "https://files.pythonhosted.org/packages/57/63/f126158097d6d9540d121a561440c9ff93f9e5e647c4c9366c81efd2a2a2/python-consume-0.1.0.tar.gz" } ], "0.1.1": [ { "comment_text": "", "digests": { "md5": "c16a522c911d6ebef728bf991263477b", "sha256": "85e6fec3b23a45f419005168e7add78eb9f302af5c130de161251b431e34b901" }, "downloads": -1, "filename": "python-consume-0.1.1.tar.gz", "has_sig": false, "md5_digest": "c16a522c911d6ebef728bf991263477b", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 139295, "upload_time": "2011-03-04T21:57:21", "url": "https://files.pythonhosted.org/packages/6d/f0/10069f06306050c9dbd0ec741e4224562d44c2d09bcf1d1435675a1ae012/python-consume-0.1.1.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "c16a522c911d6ebef728bf991263477b", "sha256": "85e6fec3b23a45f419005168e7add78eb9f302af5c130de161251b431e34b901" }, "downloads": -1, "filename": "python-consume-0.1.1.tar.gz", "has_sig": false, "md5_digest": "c16a522c911d6ebef728bf991263477b", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 139295, "upload_time": "2011-03-04T21:57:21", "url": "https://files.pythonhosted.org/packages/6d/f0/10069f06306050c9dbd0ec741e4224562d44c2d09bcf1d1435675a1ae012/python-consume-0.1.1.tar.gz" } ] }