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

Edge weights in GML files #160

Open
oxy86 opened this issue Dec 12, 2024 · 1 comment
Open

Edge weights in GML files #160

oxy86 opened this issue Dec 12, 2024 · 1 comment
Assignees
Milestone

Comments

@oxy86
Copy link
Member

oxy86 commented Dec 12, 2024

Latest version seems to ignore the weight keyword in Edges. Fix needed.

@oxy86 oxy86 self-assigned this Dec 12, 2024
@oxy86
Copy link
Member Author

oxy86 commented Feb 25, 2025

graph [
directed 1

node [
id 1
label "A"
]

node [
id 2
label "B"
]

edge [
source 1
target 2
weight 2.5
]
]

@oxy86 oxy86 added this to the 3.2 milestone Feb 25, 2025
oxy86 added a commit that referenced this issue Feb 25, 2025
Fix GML parser to correctly read and apply edge weights

- Added detection and parsing of the `weight` attribute inside `edge` blocks.
- Ensured edge weight is stored and passed correctly when creating edges.
- Set a default edge weight of `1.0` if no weight is provided.
- Improved debug output for better traceability of edge attributes.
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