allfed / allfed-integrated-model

Integrated model to calculate the effects of resilient foods in catastrophic events
https://allfed.github.io/allfed-integrated-model/
GNU General Public License v3.0
11 stars 10 forks source link

immediate_outdoor_crops is very slightly negative sometimes #144

Open morganrivers opened 2 months ago

morganrivers commented 2 months ago

line 509 in interpret.py

        # TODO BUG?? Noticed this is failing at 3 decimal place rounding...
        immediate_outdoor_crops_rounded = (
            self.immediate_outdoor_crops.get_rounded_to_decimal(1)
        )

This is saying, that sometimes immediate_outdoor_crops rounded in every month to within 0.1% is negative (so sometimes we get -0.05% or so).

Not sure why but also, probably not a big deal.

morganrivers commented 2 months ago

probably optimizer is rounding and these roundings accumulate over the 120 months. But could be another issue.