mitrefireline / simfire

An open-source wildfire simulator written in Python and meant to be used to train reinforcement learning (RL) agents.
https://mitrefireline.github.io/simfire/
Apache License 2.0
30 stars 2 forks source link

Calculation of pad distance in LandFireLatLongBox init insufficient for large map sizes #29

Open afennelly-mitre opened 5 months ago

afennelly-mitre commented 5 months ago

In commit 7466bde33427680b4cf624ba3d247a0ced46e109, we introduced the pad_distance attribute to the LandFireLatLongBox class. The pad_distance uses a fixed constant of 100 to pull "extra data" from landfire to ensure that the resulting fuel.shape is equivalent to the user provided area.screen_size tuple.

However, this does not work when using larger map sizes, ie. there is an upper bound when using 100 where if the area.screen_size is above this upper bound, the resulting fuel.shape is no longer equivalent to the provided fuel.shape.

I haven't tested this rigorously to discover the true upper bound, but I have found that setting the constant to 250 upholds the equivalent shape assumption for map sizes less than or equal to (768, 768).