You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/CloudGraphsDFG/services/CloudGraphsDFG.jl
+2-2Lines changed: 2 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -577,12 +577,12 @@ Optionally provide a distance to specify the number of edges should be followed.
577
577
Optionally provide an existing subgraph addToDFG, the extracted nodes will be copied into this graph. By default a new subgraph will be created.
578
578
Note: By default orphaned factors (where the subgraph does not contain all the related variables) are not returned. Set includeOrphanFactors to return the orphans irrespective of whether the subgraph contains all the variables.
"(n:$(dfg.userId):$(dfg.robotId):$(dfg.sessionId):$(node.label))-[FACTORGRAPH*0..$distance]-(node:$(dfg.userId):$(dfg.robotId):$(dfg.sessionId)) WHERE (n:VARIABLE OR n:FACTOR OR node:VARIABLE OR node:FACTOR) and not (node:SESSION)")
585
+
"(n:$(dfg.userId):$(dfg.robotId):$(dfg.sessionId):$(node.label))-[FACTORGRAPH*0..$distance]-(node:$(dfg.userId):$(dfg.robotId):$(dfg.sessionId)) WHERE (n:VARIABLE OR n:FACTOR OR node:VARIABLE OR node:FACTOR) and not (node:SESSION) and (node.solvable >= $solvable)")
# Variable sorting when using a factor (function order is important)
315
316
if vert.dfgNode isa DFGFactor
@@ -328,7 +329,7 @@ Optionally provide a distance to specify the number of edges should be followed.
328
329
Optionally provide an existing subgraph addToDFG, the extracted nodes will be copied into this graph. By default a new subgraph will be created.
329
330
Note: By default orphaned factors (where the subgraph does not contain all the related variables) are not returned. Set includeOrphanFactors to return the orphans irrespective of whether the subgraph contains all the variables.
330
331
"""
331
-
functiongetSubgraphAroundNode(dfg::GraphsDFG{P}, node::T, distance::Int64=1, includeOrphanFactors::Bool=false, addToDFG::GraphsDFG=GraphsDFG{P}())::GraphsDFGwhere {P <:AbstractParams, T <:DFGNode}
332
+
functiongetSubgraphAroundNode(dfg::GraphsDFG{P}, node::T, distance::Int64=1, includeOrphanFactors::Bool=false, addToDFG::GraphsDFG=GraphsDFG{P}(); solvable::Int=0)::GraphsDFGwhere {P <:AbstractParams, T <:DFGNode}
332
333
if!haskey(dfg.labelDict, node.label)
333
334
error("Variable/factor with label '$(node.label)' does not exist in the factor graph")
334
335
end
@@ -342,7 +343,7 @@ function getSubgraphAroundNode(dfg::GraphsDFG{P}, node::T, distance::Int64=1, in
342
343
for (key, node) in curList
343
344
neighbors =in_neighbors(node, dfg.g) #Don't use out_neighbors! It enforces directiveness even if we don't want it
@@ -385,13 +395,15 @@ Optionally provide a distance to specify the number of edges should be followed.
385
395
Optionally provide an existing subgraph addToDFG, the extracted nodes will be copied into this graph. By default a new subgraph will be created.
386
396
Note: By default orphaned factors (where the subgraph does not contain all the related variables) are not returned. Set includeOrphanFactors to return the orphans irrespective of whether the subgraph contains all the variables.
387
397
"""
388
-
functiongetSubgraphAroundNode(dfg::LightDFG{P,V,F}, node::DFGNode, distance::Int64=1, includeOrphanFactors::Bool=false, addToDFG::LightDFG=LightDFG{P,V,F}())::LightDFGwhere {P <:AbstractParams, V <:AbstractDFGVariable, F <:AbstractDFGFactor}
398
+
functiongetSubgraphAroundNode(dfg::LightDFG{P,V,F}, node::DFGNode, distance::Int64=1, includeOrphanFactors::Bool=false, addToDFG::LightDFG=LightDFG{P,V,F}(); solvable::Int=0)::LightDFGwhere {P <:AbstractParams, V <:AbstractDFGVariable, F <:AbstractDFGFactor}
389
399
if!exists(dfg,node.label)
390
400
error("Variable/factor with label '$(node.label)' does not exist in the factor graph")
391
401
end
392
402
393
403
# Get a list of all unique neighbors inside 'distance'
0 commit comments