Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

structural entropy calculation #2

Open
Mutual-Luo opened this issue Jul 24, 2024 · 0 comments
Open

structural entropy calculation #2

Mutual-Luo opened this issue Jul 24, 2024 · 0 comments

Comments

@Mutual-Luo
Copy link

i think there is something wrong in code
"""
def CombineDelta(node1, node2, cut_v, g_vol):
v1 = node1.vol + 1
v2 = node2.vol + 1
g1 = node1.g + 1
g2 = node2.g + 1
v12 = v1 + v2
return ((v1 - g1) * math.log2(v12 / v1) + (v2 - g2) * math.log2(v12 / v2) -
2 * cut_v * math.log2(g_vol / v12)) / g_vol
"""

I think it should return """ 2 * cut_v * math.log2(g_12 / vol) / g_vol """

if there is something that I misundersand, can you supply a further information of the calculation?

thank you very much

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

No branches or pull requests

1 participant