Skip to content
This repository has been archived by the owner on Jan 6, 2025. It is now read-only.

deposit_scale_factor might be zero #8

Open
pirapira opened this issue Apr 20, 2017 · 3 comments
Open

deposit_scale_factor might be zero #8

pirapira opened this issue Apr 20, 2017 · 3 comments

Comments

@pirapira
Copy link
Member

In initialize_epoch, new deposit_scale_factor is computed as:

    self.consensus_messages[epoch].deposit_scale_factor = something * (1 - 2 * base_coeff)

This can be zero because base_coeff can be 0.5:

    base_coeff = 1.0 / sqrt * (self.reward_at_1m_eth / 1000)

when sqrt happens to be 160.

This seems like a problem because sometimes deposit_scale_factor divides some other scaling factors.

@krtschmr
Copy link

krtschmr commented May 7, 2017

nice catch

@vbuterin
Copy link
Contributor

Perhaps to solve this cleanly, we just do something like resize_factor = min(resize_factor, 0.9)?

@pirapira
Copy link
Member Author

I need to draw graphs to figure out what's going on.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants