diff --git a/.gitignore b/.gitignore index 7a2d4ff..8c6e68b 100644 --- a/.gitignore +++ b/.gitignore @@ -2,4 +2,4 @@ *.png *.jpg *.egg-info -NodesPostPro.egg-info \ No newline at end of file +NodesPostPro.egg-info/* \ No newline at end of file diff --git a/NodesPostPro.egg-info/PKG-INFO b/NodesPostPro.egg-info/PKG-INFO deleted file mode 100644 index a42aec0..0000000 --- a/NodesPostPro.egg-info/PKG-INFO +++ /dev/null @@ -1,23 +0,0 @@ -Metadata-Version: 2.1 -Name: NodesPostPro -Version: 0.1 -Summary: Node based post processing python tool. -Home-page: https://github.com/Zelfior/NodesPostPro -Author: Zelfior -License: MIT License -Description: ## NodesPostPro - - "One Module to rule them all, One Module to find them, One Module to bring them all and in ergonomy bind them." - - NodesPostPro is a node based interface to post-process data using numpy, panda, sklearn features and plot them using matplotlib. - - It uses the NodeGraphQt framework. More information about this framework can be found here: - - https://jchanvfx.github.io/NodeGraphQt - -Platform: UNKNOWN -Classifier: Operating System :: OS Independent -Classifier: License :: OSI Approved :: MIT License -Classifier: Programming Language :: Python :: 3.6 -Requires-Python: >=3.6 -Description-Content-Type: text/markdown diff --git a/NodesPostPro.egg-info/SOURCES.txt b/NodesPostPro.egg-info/SOURCES.txt deleted file mode 100644 index 494bbb2..0000000 --- a/NodesPostPro.egg-info/SOURCES.txt +++ /dev/null @@ -1,8 +0,0 @@ -README.md -setup.cfg -setup.py -NodesPostPro.egg-info/PKG-INFO -NodesPostPro.egg-info/SOURCES.txt -NodesPostPro.egg-info/dependency_links.txt -NodesPostPro.egg-info/requires.txt -NodesPostPro.egg-info/top_level.txt \ No newline at end of file diff --git a/NodesPostPro.egg-info/dependency_links.txt b/NodesPostPro.egg-info/dependency_links.txt deleted file mode 100644 index 8b13789..0000000 --- a/NodesPostPro.egg-info/dependency_links.txt +++ /dev/null @@ -1 +0,0 @@ - diff --git a/NodesPostPro.egg-info/requires.txt b/NodesPostPro.egg-info/requires.txt deleted file mode 100644 index 9433efb..0000000 --- a/NodesPostPro.egg-info/requires.txt +++ /dev/null @@ -1,3 +0,0 @@ -Qt.py>=1.2.0 -NodeGraphQt>=0.5.5 -PySide2>=5.15 diff --git a/NodesPostPro.egg-info/top_level.txt b/NodesPostPro.egg-info/top_level.txt deleted file mode 100644 index 8b13789..0000000 --- a/NodesPostPro.egg-info/top_level.txt +++ /dev/null @@ -1 +0,0 @@ - diff --git a/NodesPostPro/examples/external_iterator_column_plot.json b/NodesPostPro/examples/external_iterator_column_plot.json new file mode 100644 index 0000000..f105243 --- /dev/null +++ b/NodesPostPro/examples/external_iterator_column_plot.json @@ -0,0 +1,506 @@ +{ + "graph":{ + "layout_direction":0, + "acyclic":true, + "pipe_collision":false, + "pipe_slicing":false, + "pipe_style":1, + "accept_connection_types":{}, + "reject_connection_types":{} + }, + "nodes":{ + "0x204f9580520":{ + "type_":"Pandas.LoadFileNode", + "icon":null, + "name":"Read CSV file", + "color":[ + 13, + 18, + 23, + 255 + ], + "border_color":[ + 74, + 84, + 85, + 255 + ], + "text_color":[ + 255, + 255, + 255, + 180 + ], + "disabled":false, + "selected":false, + "visible":true, + "width":373.0, + "height":193.0, + "pos":[ + -601.5124006934375, + 3.2502000111844893 + ], + "layout_direction":0, + "port_deletion_allowed":false, + "subgraph_session":{}, + "custom":{ + "is_valid":true, + "Browse file":true, + "Filename":"C:\\Users\\tm787802\\Desktop\\NodesPostPro\\NodesPostPro\\example_files\\test.csv", + "Filename_label":"", + "Separator":",", + "Separator_label":"", + "Information":"Columns : 30, lines : 6281" + } + }, + "0x204f95be100":{ + "type_":"Matplotlib.PlotNode", + "icon":null, + "name":"Plot", + "color":[ + 13, + 18, + 23, + 255 + ], + "border_color":[ + 74, + 84, + 85, + 255 + ], + "text_color":[ + 255, + 255, + 255, + 180 + ], + "disabled":false, + "selected":false, + "visible":true, + "width":223.0, + "height":190.9, + "pos":[ + 710.4162049838989, + -19.5670474200504 + ], + "layout_direction":0, + "port_deletion_allowed":false, + "subgraph_session":{}, + "custom":{ + "is_valid":true, + "linestyle":"solid", + "Priority":0, + "marker":"None", + "Information":"" + } + }, + "0x204f963efa0":{ + "type_":"Matplotlib.PltFigureNode", + "icon":null, + "name":"Figure", + "color":[ + 13, + 18, + 23, + 255 + ], + "border_color":[ + 74, + 84, + 85, + 255 + ], + "text_color":[ + 255, + 255, + 255, + 180 + ], + "disabled":false, + "selected":false, + "visible":true, + "width":833.0, + "height":834.5500000000001, + "pos":[ + 1004.1494588234165, + -19.5670474200504 + ], + "layout_direction":0, + "port_deletion_allowed":false, + "subgraph_session":{}, + "custom":{ + "is_valid":true, + "Title":"", + "Title_label":"", + "x_log":false, + "y_log":false, + "legend":true, + "color_bar":false, + "canvas_width":"6", + "canvas_height":"6", + "Plot_Widget":"", + "Information":"" + } + }, + "0x204fbae04f0":{ + "type_":"List.GetListElementNode", + "icon":null, + "name":"Get element", + "color":[ + 13, + 18, + 23, + 255 + ], + "border_color":[ + 74, + 84, + 85, + 255 + ], + "text_color":[ + 255, + 255, + 255, + 180 + ], + "disabled":false, + "selected":false, + "visible":true, + "width":343.0, + "height":105.85000000000001, + "pos":[ + -151.69467556148243, + 112.1360366329626 + ], + "layout_direction":0, + "port_deletion_allowed":false, + "subgraph_session":{}, + "custom":{ + "is_valid":true, + "Input Index":"0", + "Input Index_label":"Input Index : 2", + "Information":"Type: str" + } + }, + "0x204fbb772e0":{ + "type_":"Pandas.GetColumnNode", + "icon":null, + "name":"Get column from name", + "color":[ + 13, + 18, + 23, + 255 + ], + "border_color":[ + 74, + 84, + 85, + 255 + ], + "text_color":[ + 255, + 255, + 255, + 180 + ], + "disabled":false, + "selected":false, + "visible":true, + "width":373.0, + "height":105.85000000000001, + "pos":[ + 247.27253917064616, + 3.6471348378718673 + ], + "layout_direction":0, + "port_deletion_allowed":false, + "subgraph_session":{}, + "custom":{ + "is_valid":true, + "Column name":"", + "Column name_label":"Column name : TMER", + "Information":"Output shape : (6281, 1)" + } + }, + "0x204fbb5dd30":{ + "type_":"Iterator.ExternalNode", + "icon":null, + "name":"External", + "color":[ + 13, + 18, + 23, + 255 + ], + "border_color":[ + 74, + 84, + 85, + 255 + ], + "text_color":[ + 255, + 255, + 255, + 180 + ], + "disabled":false, + "selected":false, + "visible":true, + "width":235.0, + "height":194.05, + "pos":[ + -462.2008647760189, + 225.49799766345154 + ], + "layout_direction":0, + "port_deletion_allowed":false, + "subgraph_session":{}, + "custom":{ + "is_valid":true, + "Min":"2", + "Max":"5", + "Step":"1", + "Execute":true, + "Information":"Values count: 3" + } + }, + "0x204fbb7e880":{ + "type_":"String.ReplaceNode", + "icon":null, + "name":"Replace", + "color":[ + 13, + 18, + 23, + 255 + ], + "border_color":[ + 74, + 84, + 85, + 255 + ], + "text_color":[ + 255, + 255, + 255, + 180 + ], + "disabled":false, + "selected":false, + "visible":true, + "width":261.0, + "height":163.6, + "pos":[ + 271.58185015133927, + 204.18511973376786 + ], + "layout_direction":0, + "port_deletion_allowed":false, + "subgraph_session":{}, + "custom":{ + "is_valid":true, + "From":"XXX", + "From_label":"", + "To":"", + "To_label":"To : TMER", + "Information":"Output: Plot_column_TMER" + } + }, + "0x204fbb7ee80":{ + "type_":"Input.InputStringNode", + "icon":null, + "name":"String", + "color":[ + 13, + 18, + 23, + 255 + ], + "border_color":[ + 74, + 84, + 85, + 255 + ], + "text_color":[ + 255, + 255, + 255, + 180 + ], + "disabled":false, + "selected":false, + "visible":true, + "width":258.0, + "height":68.05000000000001, + "pos":[ + -68.3266622189262, + 254.67210463418002 + ], + "layout_direction":0, + "port_deletion_allowed":false, + "subgraph_session":{}, + "custom":{ + "is_valid":true, + "Value":"Plot_column_XXX" + } + }, + "0x204fbb9b100":{ + "type_":"Matplotlib.SaveFigureNode", + "icon":null, + "name":"Save Figure", + "color":[ + 13, + 18, + 23, + 255 + ], + "border_color":[ + 74, + 84, + 85, + 255 + ], + "text_color":[ + 255, + 255, + 255, + 180 + ], + "disabled":false, + "selected":false, + "visible":true, + "width":254.0, + "height":86.95, + "pos":[ + 1913.2314584364876, + -19.608521535952264 + ], + "layout_direction":0, + "port_deletion_allowed":false, + "subgraph_session":{}, + "custom":{ + "is_valid":true, + "canvas_dpi":"100", + "Information":"" + } + } + }, + "connections":[ + { + "out":[ + "0x204f9580520", + "Output DataFrame" + ], + "in":[ + "0x204fbb772e0", + "Input DataFrame" + ] + }, + { + "out":[ + "0x204f9580520", + "Columns names" + ], + "in":[ + "0x204fbae04f0", + "Input List" + ] + }, + { + "in":[ + "0x204f95be100", + "Y" + ], + "out":[ + "0x204fbb772e0", + "Output DataFrame" + ] + }, + { + "in":[ + "0x204f95be100", + "label" + ], + "out":[ + "0x204fbae04f0", + "Output Element" + ] + }, + { + "out":[ + "0x204f95be100", + "Element" + ], + "in":[ + "0x204f963efa0", + "Input Plottable 1" + ] + }, + { + "out":[ + "0x204f963efa0", + "Figure" + ], + "in":[ + "0x204fbb9b100", + "Input Figure" + ] + }, + { + "in":[ + "0x204fbae04f0", + "Input Index" + ], + "out":[ + "0x204fbb5dd30", + "i" + ] + }, + { + "out":[ + "0x204fbae04f0", + "Output Element" + ], + "in":[ + "0x204fbb772e0", + "Column name" + ] + }, + { + "out":[ + "0x204fbae04f0", + "Output Element" + ], + "in":[ + "0x204fbb7e880", + "To" + ] + }, + { + "in":[ + "0x204fbb7e880", + "Input" + ], + "out":[ + "0x204fbb7ee80", + "Output Value" + ] + }, + { + "out":[ + "0x204fbb7e880", + "Output" + ], + "in":[ + "0x204fbb9b100", + "File name" + ] + } + ] +} \ No newline at end of file diff --git a/NodesPostPro/hotkeys/hotkey_functions.py b/NodesPostPro/hotkeys/hotkey_functions.py index 035a4b6..4bdfdc0 100644 --- a/NodesPostPro/hotkeys/hotkey_functions.py +++ b/NodesPostPro/hotkeys/hotkey_functions.py @@ -296,4 +296,7 @@ def internal_column_plot(graph): def iterator_random_hist(graph): load_example(graph, "iterator_random_hist.json") +def external_iterator_column_plot(graph): + load_example(graph, "external_iterator_column_plot.json") + \ No newline at end of file diff --git a/NodesPostPro/hotkeys/hotkeys.json b/NodesPostPro/hotkeys/hotkeys.json index 2a2c126..2892335 100644 --- a/NodesPostPro/hotkeys/hotkeys.json +++ b/NodesPostPro/hotkeys/hotkeys.json @@ -185,6 +185,12 @@ "label":"Random inputs and histogram", "file":"hotkeys/hotkey_functions.py", "function_name":"iterator_random_hist" + }, + { + "type":"command", + "label":"External iterator and column plot", + "file":"hotkeys/hotkey_functions.py", + "function_name":"external_iterator_column_plot" } ] }, diff --git a/NodesPostPro/nodes/iterator_nodes.py b/NodesPostPro/nodes/iterator_nodes.py index 9124cd0..d53669d 100644 --- a/NodesPostPro/nodes/iterator_nodes.py +++ b/NodesPostPro/nodes/iterator_nodes.py @@ -60,7 +60,7 @@ def update_from_input(self): def clicked_function(self): for i in range(int(self.get_property("Min")), int(self.get_property("Max")), int(self.get_property("Step"))): - self.set_output_property('i', i) + self.set_output_property('i', i, False) self.propagate() self.set_output_property('i', int(self.get_property("Min")), False)