directed-acyclic-graphs

Directed acyclic graph using d3.js without DOT

你离开我真会死。 提交于 2019-12-03 03:25:20
问题 I am trying to draw directed acyclic graph using d3.js. While searching for the layout, I came across Dagre but it seems to be of less use as I do not want to use DOT based code anywhere. If anyone knows about pure Javascript solution for this or plugin/custom layout for DAG, please let me know. Thanks in advance. 回答1: Dagre author here. Dagre doesn't include any of the graphviz code - it is pure JavaScript. It is based on similar layout techniques though; both are based on techniques from

Efficient algorithm for merging two DAGs

一个人想着一个人 提交于 2019-12-03 02:36:22
I have two weighted DAGs (directed acyclic graphs) and need to merge them into one, so I can get a topological ordering (it could be more than two in some cases). The problem is that the graphs are acyclic each, but can form a cycle together. Also, the graphs are large (100k+ nodes, 500k+ edges). Is there a clever way to merge the graphs? Equally good would be an algorithm to traverse all graphs "at once". Edit: By "merge" I mean combining all edges and vertices of both graphs together (preserving weights of course), if they do not create cycles. If an edge already exists I want to use the

DAG(directed acyclic graph) dynamic job scheduler

99封情书 提交于 2019-12-03 00:29:54
问题 I need to manage a large workflow of ETL tasks, which execution depends on time, data availability or an external event. Some jobs may fail during execution of the workflow and the system should have the ability to restart a failed workflow branch without waiting for whole workflow to finish execution. Are there any frameworks in python that can handle this? I see several core functions: DAG bulding Execution of nodes (run shell cmd with wait,logging etc.) Ability to rebuild sub-graph in

Can a failed Airflow DAG Task Retry with changed parameter

折月煮酒 提交于 2019-12-02 20:46:57
问题 With Airflow, is it possible to restart an upstream task if a downstream task fails? This seems to be against the "Acyclic" part of the term DAG. I would think this is a common problem though. Background I'm looking into using Airflow to manage a data processing workflow that has been managed manually. There is a task that will fail if a parameter x is set too high, but increasing the parameter value gives better quality results. We have not found a way to calculate a safe but maximally high

DAG(directed acyclic graph) dynamic job scheduler

无人久伴 提交于 2019-12-02 14:08:46
I need to manage a large workflow of ETL tasks, which execution depends on time, data availability or an external event. Some jobs may fail during execution of the workflow and the system should have the ability to restart a failed workflow branch without waiting for whole workflow to finish execution. Are there any frameworks in python that can handle this? I see several core functions: DAG bulding Execution of nodes (run shell cmd with wait,logging etc.) Ability to rebuild sub-graph in parent DAG during execution Ability to manual execute nodes or sub-graph while parent graph is running

Is DAG created when we perform operations over dataframes?

血红的双手。 提交于 2019-12-02 13:33:19
I have seen DAG getting generated whenever we perform any operation on RDD but what happens when we perform operations on our dataframe? When executing multiple operations on dataframe, Are those lazily evaluated just like RDD? When the catalyst optimizer comes into the picture? I am sort of confused between these. If anyone can throw some light on these topics, it would be really of great help. Thanks Every operation on a Dataset , continuous processing mode notwithstanding, is translated into a sequence of operations on internal RDDs . Therefore concept of DAG is by all means applicable. By

Can a failed Airflow DAG Task Retry with changed parameter

徘徊边缘 提交于 2019-12-02 09:40:42
With Airflow, is it possible to restart an upstream task if a downstream task fails? This seems to be against the "Acyclic" part of the term DAG. I would think this is a common problem though. Background I'm looking into using Airflow to manage a data processing workflow that has been managed manually. There is a task that will fail if a parameter x is set too high, but increasing the parameter value gives better quality results. We have not found a way to calculate a safe but maximally high parameter x. The process by hand has been to restart the job if failed with a lower parameter until it

DAG (Directed acyclic graph) - QAbstractItemModel

风格不统一 提交于 2019-12-02 07:53:05
I am planning on creating a Node Graph in pyqt. The abstract models that qt provides work for 1D, 2D and Tree data but the abstract class seems to break down for something like a node graph. In particular the "parent" function in QAbstractModel returns QModelIndex of a single parent. In a DAG I will may have multiple parents. One resource I found was this blog post: http://invalidmagic.wordpress.com/2009/12/10/qgraphicsscene-used-as-a-qabstractitemmodel/ It provides some useful information, but I can't seem figure how the model represents the concept of multiple parents. I'm looking for

How to assign “levels” to vertices of an acyclic directed graph?

点点圈 提交于 2019-12-01 00:56:01
I have an acyclic directed graph. I would like to assign levels to each vertex in a manner that guarantees that if the edge (v1,v2) is in the graph, then level(v1) > level(v2). I would also like it if level(v1) = level(v3) whenever (v1,v2) and (v3,v2) are in the graph. Also, the possible levels are discrete (might as well take them to be the natural numbers). The ideal case would be that level(v1) = level(v2) + 1 whenever (v1,v2) is in the graph and there is no other path from v1 to v2, but sometimes that isn't possible with the other constraints - e.g, consider a graph on five vertices with

d3.js, collapsible tree - how to connect different parents with same child

|▌冷眼眸甩不掉的悲伤 提交于 2019-11-30 19:53:08
问题 So I am using http://bl.ocks.org/mbostock/4339083 to create a collapsible tree and it works great. Now the thing is I have some nodes which have the same children, so I want to know if there is any way to visualize the graph in such a way that both the parents expand to the same child? So basically when you expand the node of a parent it should automatically expand the node of the other parent leading to the same common child, is this possible with any graph? 回答1: From your description, I