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

Question about can_use_edge_weights() #58

Open
Rsugihara01 opened this issue Jan 18, 2024 · 2 comments
Open

Question about can_use_edge_weights() #58

Rsugihara01 opened this issue Jan 18, 2024 · 2 comments

Comments

@Rsugihara01
Copy link

Hey,
I am using grape to evaluate some embedding methods on my graphs I made with Graph.from_pd().
My graphs are directed graph with weighted edges.

When I looked help(Node2VecCBOWEnsmallen), it says

 |  can_use_edge_weights() -> bool from builtins.type
 |      Returns whether the model can optionally use edge weights.

I'm sorry if I've missed any reading, but I couldn't find any arguments to state whether to use edge weights.

Does it mean when embedder.can_use_edge_weights() returns True and the graph has edge weights,
any embedder just uses edge weights automatically?
and if i want to change the graph to unweighted edges, I need to remake graph using Graph.from_pd() and delete argument edge_weight_column to make graph unweighted edge?

@LucaCappelletti94
Copy link
Member

Yes, if you load the edge weights in the graph the algorithms will use the edge weights.

@Rsugihara01
Copy link
Author

Thanks for your quick reply!
I just want to be sure about it, please feel free to close this issue. Thank you!

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

2 participants