|
|
| TestScenario (const TestScenario &rhs)=delete |
| |
|
| TestScenario (TestScenario &&rhs)=delete |
| |
|
TestScenario & | operator= (const TestScenario &rhs)=delete |
| |
|
TestScenario & | operator= (TestScenario &&rhs)=delete |
| |
| | TestScenario (Model *model, const XYIdx &start_xy, const StartPoint &start_point, const int start_date, const DurationSize end_date, const ptr< const FireWeather > weather, ptr< SafeVector > final_sizes) |
| | Constructor.
|
| |
|
| Scenario (Scenario &&rhs) noexcept |
| |
|
| Scenario (const Scenario &rhs)=delete |
| |
|
Scenario & | operator= (Scenario &&rhs) noexcept |
| |
|
Scenario & | operator= (const Scenario &rhs) const =delete |
| |
| Scenario * | reset_with_new_start (const XYIdx &start_cell, ptr< SafeVector > final_sizes) |
| | Assign start Cell, reset thresholds and set SafeVector to output results to.
|
| |
| Scenario * | reset (mt19937_64 *mt_extinction, mt19937_64 *mt_spread, ptr< SafeVector > final_sizes) |
| | Reset thresholds and set SafeVector to output results to.
|
| |
| void | burn (const Event &event) |
| | Burn cell that Event takes place in.
|
| |
| void | cancel (bool show_warning) noexcept |
| |
|
Cell | cell (const XYIdx xy) const |
| |
|
constexpr Idx | height () const |
| |
|
constexpr Idx | width () const |
| |
| constexpr MathSize | cellSize () const |
| | Cell width and height (m)
|
| |
| constexpr int64_t | simulation () const |
| | Simulation number.
|
| |
|
constexpr DurationSize | current_time () const |
| |
| constexpr const StartPoint & | startPoint () const |
| | StartPoint that provides sunrise/sunset times.
|
| |
| constexpr DurationSize | startTime () const |
| | Simulation start time.
|
| |
| constexpr size_t | id () const |
| | Identifier.
|
| |
| constexpr const Model & | model () const |
| | Model this Scenario is running in.
|
| |
| constexpr DurationSize | dayStart (const size_t for_day) const |
| | Sunrise time for given day.
|
| |
| constexpr DurationSize | dayEnd (const size_t for_day) const |
| | Sunset time for given day.
|
| |
| ptr< const FwiWeather > | weather (const DurationSize time) const |
| | FwiWeather for given time.
|
| |
|
ptr< const FwiWeather > | weather_daily (const DurationSize time) const |
| |
| constexpr int | nd (const DurationSize time) const |
| | Difference between date and the date of minimum foliar moisture content.
|
| |
| ThresholdSize | extinctionThreshold (const DurationSize time) const |
| | Get extinction threshold for given time.
|
| |
| ThresholdSize | spreadThresholdByRos (const DurationSize time) const |
| | Get spread threshold for given time.
|
| |
| constexpr bool | isAtNight (const DurationSize time) const |
| | Whether or not time is after sunrise and before sunset.
|
| |
| MathSize | minimumFfmcForSpread (const DurationSize time) const noexcept |
| | Minimum Fine Fuel Moisture Code for spread to be possible.
|
| |
| bool | isSurrounded (const XYIdx &location) const |
| | Whether or not the given Location is surrounded by cells that are burnt.
|
| |
| Scenario * | run (map< DurationSize, shared_ptr< ProbabilityMap > > *probabilities) |
| | Run the Scenario.
|
| |
| void | scheduleFireSpread (const Event &event) |
| | Schedule a fire spread Event.
|
| |
| MathSize | currentFireSize () const |
| | Current fire size (ha)
|
| |
| bool | canBurn (const XYIdx &location) const |
| | Whether or not a Cell can burn.
|
| |
| bool | hasBurned (const XYIdx &location) const |
| | Whether or not Location has burned already.
|
| |
| void | addEvent (Event &&event) |
| | Add an Event to the queue.
|
| |
| void | evaluateNextEvent () |
| | Evaluate next Event in the queue.
|
| |
|
void | endSimulation () noexcept |
| | End the simulation.
|
| |
| void | addSaveByOffset (int offset) |
| | Add a save point for simulation data at the given offset.
|
| |
| void | addSave (const DurationSize time) |
| | Add a save point for simulation data at given time.
|
| |
| FileList | saveObservers (const string_view output_directory, const string_view base_name) const |
| | Tell Observers to save their data with base file name.
|
| |
| FileList | saveObservers (const string_view output_directory, DurationSize time) const |
| | Tell Observers to save their data for the given time.
|
| |
| FileList | saveIntensity (const string_view output_directory, const string_view base_name) const |
| | Save burn intensity information.
|
| |
| bool | ran () const noexcept |
| | Whether or not this Scenario has run already.
|
| |
| bool | survives (const DurationSize time, const Cell &cell, const DurationSize time_at_location) const |
| | Whether or not the fire survives the conditions.
|
| |
| vector< DurationSize > | savePoints () const |
| | List of what times the simulation will save.
|
| |
| void | saveStats (DurationSize time) const |
| | Save state of Scenario at given time.
|
| |
| void | registerObserver (IObserver *observer) |
| | Register an IObserver that will be notified when Cells burn.
|
| |
| void | notify (const Event &event) const |
| | Notify IObservers that a Cell has burned.
|
| |
| void | evaluate (const Event &event) |
| | Take whatever steps are necessary to process the given Event.
|
| |
|
void | clear () noexcept |
| | Clear the Event list and all other data.
|
| |
| | Scenario (Model *model, size_t id, const ptr< const FireWeather > weather, const ptr< const FireWeather > weather_daily, DurationSize start_time, const shared_ptr< Perimeter > &perimeter, const XYIdx &start_xy, StartPoint start_point, Day start_day, Day last_date) |
| | Constructor.
|
| |
|
| static size_t | completed () noexcept |
| | Number of Scenarios that have completed running.
|
| |
| static size_t | count () noexcept |
| | Number of Scenarios that have been initialized.
|
| |
| static size_t | total_steps () noexcept |
| | Total number of spread events for all Scenarios.
|
| |
|
string | log_prefix_ {} |
| |
|
list< unique_ptr< IObserver, IObserver_deleter > > | observers_ {} |
| | Observers to be notified when cells burn.
|
| |
|
vector< DurationSize > | save_points_ |
| | List of times to save simulation.
|
| |
|
vector< ThresholdSize > | extinction_thresholds_ {} |
| | Thresholds used to determine if extinction occurs.
|
| |
|
vector< ThresholdSize > | spread_thresholds_by_ros_ {} |
| | Thresholds used to determine if spread occurs.
|
| |
|
DurationSize | current_time_ |
| | Current time for this Scenario.
|
| |
|
CellPointsMap | points_ |
| |
|
BurnedData | unburnable_ {} |
| | Contains information on cells that are not burnable.
|
| |
|
set< Event > | scheduler_ |
| | Event scheduler used for ordering events.
|
| |
|
unique_ptr< IntensityMap > | intensity_ {nullptr} |
| | Map of what intensity each cell has burned at.
|
| |
|
shared_ptr< Perimeter > | perimeter_ {nullptr} |
| | Perimeter used to start Scenario from.
|
| |
|
map< SpreadKey, SpreadInfo > | spread_info_ {} |
| | Calculated SpreadInfo for SpreadKey for current time.
|
| |
|
map< XYIdx, DurationSize > | arrival_ {} |
| | Map of when Cell had first Point arrive in it.
|
| |
|
MathSize | max_ros_ |
| | Maximum rate of spread for current time.
|
| |
|
XYIdx | start_xy_ {} |
| | Cell that the Scenario starts from if no Perimeter.
|
| |
|
ptr< const FireWeather > | weather_ {nullptr} |
| | Hourly weather to use for this Scenario.
|
| |
|
ptr< const FireWeather > | weather_daily_ {nullptr} |
| | Weather stream to use for spread and extinction probability.
|
| |
|
Model * | model_ {nullptr} |
| | Model this Scenario is being run in.
|
| |
|
map< DurationSize, shared_ptr< ProbabilityMap > > * | probabilities_ {nullptr} |
| | Map of ProbabilityMaps by time snapshot for them was taken.
|
| |
|
ptr< SafeVector > | final_sizes_ {nullptr} |
| | Where to append the final size of this Scenario when run is complete.
|
| |
|
StartPoint | start_point_ |
| | Origin of fire.
|
| |
|
size_t | id_ |
| | Identifier.
|
| |
|
DurationSize | start_time_ |
| | Start time (decimal days)
|
| |
|
DurationSize | last_save_ |
| | Which save point is the last one.
|
| |
|
size_t | current_time_index_ = numeric_limits<size_t>::max() |
| | Time index for current time.
|
| |
|
int64_t | simulation_ |
| | Simulation number.
|
| |
|
Day | start_day_ |
| | First day of simulation.
|
| |
|
Day | last_date_ |
| | Last day of simulation.
|
| |
|
bool | ran_ |
| | Whether or not this Scenario has completed running.
|
| |
|
bool | cancelled_ = false |
| | Whether this has been cancelled.
|
| |
|
size_t | step_ |
| | How many times point spread event has happened.
|
| |
|
LogPoints | points_log_ {} |
| | Point logging.
|
| |
|
size_t | oob_spread_ {} |
| | How many times this scenario tried to spread out of bounds.
|
| |
A Scenario run with constant fuel, weather, and topography.