[
https://issues.apache.org/jira/browse/FLINK-2905?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14976461#comment-14976461
]
Martin Junghanns commented on FLINK-2905:
-----------------------------------------
Hi, I agree with you that Option 3 is the most intuitive one. But as it is just
a deduction from Option 2, I thought about two basic cases for intersection.
Let's focus on the edges:
E(G1):
{code}
1, 3, 13
{code}
E(G2):
{code}
1, 3, 13
1, 3, 14
{code}
Call 1
{{G' = G1.intersect(G2, considerEdgeValues = true)}}
E(G')
{code}
1, 3, 13 // G1
1, 3, 13 // G2
{code}
Call 2
{{G' = G1.intersect(G2, considerEdgeValues = false)}}
E(G')
{code}
1, 3, 13 // G1
1, 3, 13 // G2
1, 3, 14 // G2
{code}
If users are interested in Option 3, they can call {{E(G').distinct()}}. So
imho, those two calls are the most basic ones and leave more specific analytics
to the user (e.g. distinct, edge aggregation, ...). Wdyt?
> Add intersect method to Graph class
> -----------------------------------
>
> Key: FLINK-2905
> URL: https://issues.apache.org/jira/browse/FLINK-2905
> Project: Flink
> Issue Type: New Feature
> Components: Gelly
> Affects Versions: 0.10
> Reporter: Martin Junghanns
> Assignee: Martin Junghanns
> Priority: Minor
>
> Currently, the Gelly Graph supports the set operations
> {{Graph.union(otherGraph)}} and {{Graph.difference(otherGraph)}}. It would be
> nice to have a {{Graph.intersect(otherGraph)}} method, where the resulting
> graph contains all vertices and edges contained in both input graphs.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)