Contains all the immutable information regarding a simulation that is common between Scenarios.
More...
|
|
Cell | cell (const XYIdx xy) const |
| |
|
constexpr Idx | height () const |
| |
|
constexpr Idx | width () const |
| |
| constexpr MathSize | cellSize () const |
| | Cell width and height (m)
|
| |
| constexpr const Environment & | environment () const |
| | Environment simulation is occurring in.
|
| |
| constexpr Clock::time_point | runningSince () const |
| | Time that execution started.
|
| |
| constexpr Clock::duration | timeLimit () const |
| | Maximum amount of time simulation can run for before being stopped.
|
| |
| constexpr Clock::duration | interimTimeLimit () const |
| | Time between generating interim outputs (s)
|
| |
| bool | shouldStop () const noexcept |
| | Whether or not simulation has exceeded any limits that mean it should stop.
|
| |
| bool | isOutOfTime () const noexcept |
| | Whether or not simulation has been running longer than maximum duration.
|
| |
| bool | isUnderSimulationCountMinimum () const noexcept |
| | Whether or not simulation is under min simulation count.
|
| |
| size_t | activeSimulationsStillRequired () const noexcept |
| | How many active simulations are still needed.
|
| |
| bool | isOverSimulationCountMaximum () const noexcept |
| | Whether or not simulation is over max simulation count.
|
| |
| int | year () const noexcept |
| | What year the weather is for.
|
| |
| size_t | ignitionScenarios () const noexcept |
| | How many ignition scenarios are being used.
|
| |
| size_t | scenarioCount () const noexcept |
| | How many Scenarios are in each Iteration.
|
| |
| constexpr int | nd (const DurationSize time) const |
| | Difference between date and the date of minimum foliar moisture content.
|
| |
|
const char * | outputDirectory () const |
| |
| std::chrono::seconds | runTime () const |
| | Duration that model has run for.
|
| |
|
std::chrono::seconds | timeSinceLastSave () const |
| |
| shared_ptr< ProbabilityMap > | makeProbabilityMap (DurationSize time, DurationSize start_time, int min_value, int low_max, int med_max, int max_value) const |
| | Create a ProbabilityMap with the same extent as this.
|
| |
| | Model (const tm &start_time, const string_view output_directory, const StartPoint &start_point, Environment *env) |
| | Constructor.
|
| |
|
| Model (const tm &start_time, const string_view output_directory, const StartPoint &start_point, Environment *env, const Settings &settings) |
| |
|
| Model (Model &&rhs) noexcept=delete |
| |
|
| Model (const Model &rhs)=delete |
| |
|
Model & | operator= (Model &&rhs) noexcept=delete |
| |
|
Model & | operator= (const Model &rhs)=delete |
| |
| void | setWeather (const FwiWeather &weather, const Day start_day) |
| | Set constant weather.
|
| |
| void | readWeather (const FwiWeather &yesterday, const MathSize latitude, const string &filename) |
| | Read weather used for Scenarios.
|
| |
| void | makeStarts (Coordinates coordinates, const Point &point, const LazyPath &perim, size_t size) |
| | Make starts based on desired point and where nearest combustible cells are.
|
| |
| Iteration | readScenarios (const StartPoint &start_point, DurationSize start, Day start_day, Day last_date) |
| | Create an Iteration by initializing Scenarios.
|
| |
| ptr< const FwiWeather > | yesterday () const noexcept |
| |
|
MathSize | initial_size () const |
| | Initial fire size at start of scenario.
|
| |
|
| bool | add_statistics (vector< MathSize > *all_sizes, vector< MathSize > *means, vector< MathSize > *pct, const SafeVector &sizes) |
| | Add statistics for completed iterations.
|
| |
| map< DurationSize, shared_ptr< ProbabilityMap > > | runIterations (const StartPoint &start_point, DurationSize start, Day start_day) |
| | Run Iterations until confidence is reached.
|
| |
|
void | findAllStarts () |
| | Find all Cell(s) that can burn in entire Environment.
|
| |
| DurationSize | saveProbabilities (map< DurationSize, shared_ptr< ProbabilityMap > > &probabilities, const Day start_day, const bool is_interim) |
| |
| void | findStarts (const XYIdx &location) |
| | Find Cell(s) that can burn closest to Location.
|
| |
|
|
const string | output_directory_ |
| |
|
tm | start_time_ {} |
| | Start time of simulation.
|
| |
|
array< int, MAX_DAYS > | nd_ {} |
| | Differences between date and the date of minimum foliar moisture content.
|
| |
|
map< size_t, FireWeather > | wx_ {} |
| | Map of scenario number to weather stream.
|
| |
|
map< size_t, FireWeather > | wx_daily_ {} |
| | Map of scenario number to weather stream.
|
| |
|
vector< XYIdx > | starts_ {} |
| | Cell(s) that can burn closest to start Location.
|
| |
|
Clock::time_point | running_since_ |
| | Time to use for simulation start.
|
| |
|
Clock::duration | time_limit_ |
| | Maximum amount of time simulation can run for before being stopped.
|
| |
|
Clock::time_point | no_interim_save_since_ |
| | Time of last interim save.
|
| |
| Clock::duration | interim_save_interval_ |
| |
|
shared_ptr< Perimeter > | perimeter_ = nullptr |
| | Perimeter to use for initializing simulations.
|
| |
|
Environment * | env_ {nullptr} |
| | Environment to use for Model.
|
| |
|
int | year_ |
| | What year the weather is for.
|
| |
|
bool | is_out_of_time_ = false |
| | If simulation is out of time and should stop.
|
| |
|
bool | should_output_interim_ = false |
| | If simulation is past the time interval between interim outputs.
|
| |
|
bool | is_being_cancelled_ = false |
| | If simulation is being cancelled.
|
| |
|
atomic< size_t > | scenarios_done_ = 0 |
| | How many scenarios have been completed.
|
| |
|
atomic< size_t > | scenarios_required_done_ = 0 |
| | How many scenarios out of first iteration have been completed.
|
| |
|
atomic< size_t > | scenarios_last_save_ = 0 |
| | Scenarios completed at time of last interim save.
|
| |
|
size_t | scenarios_per_iteration_ = 0 |
| | Number of scenarios per iteration.
|
| |
|
size_t | iterations_done_ = 0 |
| | How many iterations have been completed.
|
| |
|
bool | interim_changed_ = true |
| | If interim outputs are different than last time they were saved.
|
| |
|
bool | is_under_simulation_minimum_ {true} |
| | If simulation is undex min simulation count.
|
| |
|
size_t | active_simulations_still_required_ {} |
| | Number of active simulations still required.
|
| |
|
bool | is_over_simulation_count_ = false |
| | If simulation is over max simulation count.
|
| |
| FwiWeather | yesterday_ |
| |
|
std::chrono::steady_clock::time_point | last_checked_ |
| | Time when we last checked if simulation should end.
|
| |
|
MathSize | latitude_ |
| | Latitude to use for any calcualtions.
|
| |
|
MathSize | longitude_ |
| | Longitude to use for any calcualtions.
|
| |
Contains all the immutable information regarding a simulation that is common between Scenarios.