-
Notifications
You must be signed in to change notification settings - Fork 4
Open
Labels
bugSomething isn't workingSomething isn't working
Description
https://github.com/ClimateImpactLab/dscim/blob/main/src/dscim/menu/main_recipe.py#L902-L912
If very large eta values are used, this function can create very small numbers which can exceed the smallest floats possible. As an example, with eta = 6, and no_cc_consumption and cc_consumption each being of type np.float32, parameter becomes a number usually around 10^13. The w_utility and bottom_utility variables then become numbers around -1*10^(-68) which gets stored as 0 since the float32 closest to 0 is around 10^(-38).
A fix for this may be possible by using an alternative form of the calculation or by taking advantage of the nice properties of isoelastic utility.
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working