visualize

Package Contents

class gui_mainWindow(QtWidgetList, isLight=True, actionOnWindowClosed=None, neverCloseWindow=False, title_window='Awesome Visualisation Tool', size=None)

Bases: PyQt5.QtWidgets.QMainWindow

Main class that spawns a Qt window. Use run() to display it.

set_actionOnClose(self, actionOnWindowClosed)
closeEvent(self, event)
run(self, hold=False)

Display the window

keyPressEvent(self, event)
app
start_qt_mainloop()

Starts qt mainloop, which is necessary for qt to handle events

stop_qt_mainloop()

Stops qt mainloop and resumes to program

class gui_collection_exporter

Bases: PyQt5.QtWidgets.QMainWindow

Simple gui that allows to export data

signal_has_exported
signal_has_reset
exportCollection(self)

Export the collection

reset(self)
add_data_to_collection(self, data)

Add data to the collection to export

Parameters:data – Whichever type you like
set_info(self, info)
set_collection(self, theCollection)
class DataAnimationVisuals(id=0, window_title='Animation')

Bases: PyQt5.QtWidgets.QMainWindow

Spawns a gui that includes button to create animations nicely when paired with widget_graphs_visual

SlIDER_MAXIMUM_VALUE = 500
SLIDER_MINIMUM_VALUE = 1
add_trace(self, trace_id, element_list, theTrace)

Add a trace to the animation.

Parameters:
  • trace_id – id of the trace
  • element_list – List of elements to save: [[OpenGL_item1, text_item1], [OpenGL_item2, text_item2], … [OpenGL_itemN, text_itemN]]
  • theTraceTraceVisual
Returns:

add_elementToTrace(self, trace_id, indexPoint)
delete_point(self, trace_id, thePoint)
reset_all(self)
delete_all(self)
pause_play(self)
show_all(self)
next_frame(self)
slider_handler(self)
frame_selector(self)
set_refreshTime(self)
is_empty(self)
run(self)
closeEvent(self, _)
contains_trace(self, trace_id)
export_picture(self)
class widget_graphs_visual(theGraphs, **kwargs)

Bases: PyQt5.QtWidgets.QWidget

Widget element to draw a graph. The traces and graphs to draw are defined in Graphs taken as argument. This widget is linked to the excellent third-party library pyqtgraph, under MIT license

signal_must_update
signal_graph_changed
set_graph_disposition(self, indexGraph, row=1, col=1, rowspan=1, colspan=1)

Change the graphs disposition.

Parameters:
  • indexGraph – index of the graph to change
  • row – row where to place the graph
  • col – column where to place the graph
  • rowspan – number of rows across which the graph spans
  • colspan – number of columns across which the graph spans
Returns:

__create_graph(self, idGraph)
__check_graphs(self)
on_click(self, plotDataItem, clicked_points)
update_graphs(self, singleUpdate=True)

This method is used to update the graph. This is fast but NOT safe (especially when working with threads). To limit the risks, please use self.signal_must_update.emit() instead.

Parameters:singleUpdate – if set to False, the graph will periodically refres each self.refreshtime
fast_update(self)

Use this method to update the graph in a fast way. NOT THREAD SAFE.

exportGraphs(self)

Export the graphs

get_graph(self, idGraph)

Get corresponding GraphVisual of the graph idGraph

keyPressEvent(self, event)

What happens if a key is pressed. R: reset the axes to their default value

delete_graph(self, idGraph)

Delete the graph idGraph

delete(self)
get_all_graphsVisual(self)

Return a dictionary {idGraph: GraphVisual}.

get_layout_buttons(self)

Get the QGraphicsLayout where it’s possible to add buttons, etc.

set_actionOnClick(self, theActionOnClick)

Action to perform when the graph is clicked

Parameters:theActionOnClickon_graph_click_interface
Returns:
set_title(self, idGraph, titleName, **kwargs)

Set title of the graph

Parameters:
  • idGraph – id of the graph
  • titleName – title to set
set_article_template(self, graph_size_x=8.8, graph_size_y=4.4, legendPosition='NW')

Method to set the graphs to article quality graph.

Parameters:
  • graph_size_x – width of the graph in cm
  • graph_size_y – height of the graph in cm
  • legendPosition – position of the legend (NE, SE, SW, NW)
Returns:

class widget_line_drawer(minWinHeight=300, minWinWidth=300, is_light=True)

Bases: PyQt5.QtWidgets.QWidget

Widget allowing to display several lines easily

signal_must_update
on_update_signal(self, listOfLines)
delete_lines(self, key_id)

Dele the lines :param key_id: id to delete :return:

set_lines(self, listOfLines, key_id=0, pen=None)

Set the lines to display :param listOfLines: list of [x1, y1, z1, x2, y2, z2] corresponding to lines :param key_id: id of the trace :param pen: pen used to draw the lines :return:

paintEvent(self, event, painter=None)
get_extrema_lines(self)
class widget_menuButton(theParentButton)

Bases: PyQt5.QtWidgets.QMenu

Same as QMenu, but integrates it behind a button more easily.

showEvent(self, QShowEvent)
class widget_openGL(parent=None)

Bases: PyQt5.QtWidgets.QOpenGLWidget

Interface that provides opengl capabilities. Ensures zoom, light, rotation, etc.

sizeHint(self)
minimumSizeHint(self)
set_deviceDrawer(self, theDeviceDrawer)

Set a drawer optimeed.visualize.gui.widgets.openGLWidget.DeviceDrawerInterface.DeviceDrawerInterface

set_deviceToDraw(self, theDeviceToDraw)

Set the device to draw optimeed.InterfaceDevice.InterfaceDevice

initializeGL(self)
paintGL(self)
resizeGL(self, w, h)
mousePressEvent(self, event)
mouseMoveEvent(self, event)
keyPressEvent(self, event)
wheelEvent(self, QWheelEvent)
class widget_text(theText, is_light=False, convertToHtml=False)

Bases: PyQt5.QtWidgets.QLabel

Widget able to display a text

set_text(self, theText, convertToHtml=False)

Set the text to display

class guiPyqtgraph(graphsVisual, **kwargs)

Create a gui for pyqtgraph with trace selection options, export and action on clic choices

refreshTraceList(self)

Refresh all the traces

class DeviceDrawerInterface
keyboard_push_action(self, theKey)
get_colour_scalebar(self)
get_colour_background(self)
get_opengl_options(self)
class on_graph_click_delete(theDataLink)

Bases: optimeed.visualize.gui.widgets.widget_graphs_visual.on_graph_click_interface

On Click: Delete the points from the graph, and save the modified collection

apply(self)
reset(self)
graph_clicked(self, theGraphVisual, index_graph, index_trace, indices_points)
get_name(self)
class on_graph_click_export(theDataLink)

Bases: optimeed.visualize.gui.widgets.widget_graphs_visual.on_graph_click_interface

On click: export the selected points

graph_clicked(self, theGraphVisual, index_graph, index_trace, indices_points)
reset_graph(self)
get_name(self)
class on_click_extract_pareto(theDataLink, max_x=False, max_y=False)

Bases: optimeed.visualize.gui.widgets.widget_graphs_visual.on_graph_click_interface

On click: extract the pareto from the cloud of points

graph_clicked(self, the_graph_visual, index_graph, index_trace, _)
get_name(self)
class on_graph_click_showInfo(theLinkDataGraph, visuals=None)

Bases: optimeed.visualize.gui.widgets.widget_graphs_visual.on_graph_click_interface

On click: show informations about the points (loop through attributes)

class DataInformationVisuals
delete_visual(self, theVisual)
add_visual(self, theVisual, theTrace, indexPoint)
get_new_index(self)
curr_index(self)
graph_clicked(self, theGraphVisual, index_graph, index_trace, indices_points)

Action to perform when a point in the graph has been clicked: Creates new window displaying the device and its informations

get_name(self)
class Repr_opengl(DeviceDrawer)
get_widget(self, theNewDevice)
class Repr_lines(attribute_lines)
get_widget(self, theNewDevice)
class on_graph_click_remove_trace(theDataLink)

Bases: optimeed.visualize.gui.widgets.widget_graphs_visual.on_graph_click_interface

graph_clicked(self, theGraphVisual, index_graph, index_trace, _)
get_name(self)
class on_click_copy_something(theDataLink, functionStrFromDevice)

Bases: optimeed.visualize.gui.widgets.widget_graphs_visual.on_graph_click_interface

On Click: copy something

graph_clicked(self, the_graph_visual, index_graph, index_trace, indices_points)
get_name(self)
class on_click_change_symbol(theLinkDataGraph)

Bases: optimeed.visualize.gui.widgets.widget_graphs_visual.on_graph_click_interface

On Click: Change the symbol of the point that is clicked

graph_clicked(self, theGraphVisual, index_graph, index_trace, indices_points)
get_name(self)
class on_graph_click_interface

Interface class for the action to perform when a point is clicked

class DataAnimationOpenGL(theOpenGLWidget, theId=0, window_title='Animation')

Bases: optimeed.visualize.gui.gui_data_animation.DataAnimationVisuals

Implements DataAnimationVisuals to show opengl drawing

update_widget_w_animation(self, key, index, the_data_animation)
export_widget(self, painter)
delete_key_widgets(self, key)
class DataAnimationOpenGLwText(*args, is_light=True, **kwargs)

Bases: optimeed.visualize.gui.widgets.graphsVisualWidget.examplesActionOnClick.on_click_anim.DataAnimationOpenGL

Implements DataAnimationVisuals to show opengl drawing and text

update_widget_w_animation(self, key, index, the_data_animation)
get_interesting_elements(self, devices_list)
class DataAnimationLines(is_light=True, theId=0, window_title='Animation')

Bases: optimeed.visualize.gui.gui_data_animation.DataAnimationVisuals

Implements DataAnimationVisuals to show drawing made out of lines (widget_line_drawer)

export_widget(self, painter)
delete_key_widgets(self, key)
update_widget_w_animation(self, key, index, the_data_animation)
get_interesting_elements(self, devices_list)
class DataAnimationVisualswText(is_light=True, theId=0, window_title='Animation')

Bases: optimeed.visualize.gui.widgets.graphsVisualWidget.examplesActionOnClick.on_click_anim.DataAnimationLines

Same as DataAnimationLines but also with text

update_widget_w_animation(self, key, index, the_data_animation)
class on_graph_click_showAnim(theLinkDataGraph, theAnimation)

Bases: optimeed.visualize.gui.widgets.widget_graphs_visual.on_graph_click_interface

On click: add or remove an element to animate

graph_clicked(self, theGraphVisual, index_graph, index_trace, indices_points)
get_name(self)
class LinkDataGraph
class _collection_linker
get_collection_master(self, idToGet)
is_slave(self, idToCheck)
set_same_master(self, idExistingSlave, idOtherSlave)
Parameters:
  • idExistingSlave – id collection of the existing slave
  • idOtherSlave – id collection of the new slave that has to be linked to an existing master
add_collection(self, theCollection, kwargs=None)
add_graph(self, howToPlotGraph)
createGraphs(self)
get_howToPlotGraph(self, idGraph)
get_collectionInfo(self, idCollectionInfo)
create_trace(self, collectionInfo, howToPlotGraph, idGraph)
get_all_id_graphs(self)
get_all_traces_id_graph(self, idGraph)
update_graphs(self)
is_slave(self, idGraph, idTrace)
get_idCollection_from_graph(self, idGraph, idTrace, getMaster=True)

From indices in the graph, get index of corresponding collection

get_collection_from_graph(self, idGraph, idTrace, getMaster=True)

From indices in the graph, get corresponding collection

get_dataObject_from_graph(self, idGraph, idTrace, idPoint)
get_dataObjects_from_graph(self, idGraph, idTrace, idPoint_list)
remove_element_from_graph(self, idGraph, idTrace, idPoint, deleteFromMaster=False)

Remove element from the graph, or the master collection

remove_elements_from_trace(self, idGraph, idTrace, idPoints, deleteFromMaster=False)

Performances optimisation when compared to LinkDataGraph.remove_element_from_graph()

Link data :param id_collection_graph: :param id_collection_master: :return:

remove_trace(self, idGraph, idTrace)
get_graph_and_trace_from_collection(self, idCollection)

Reverse search: from a collection, get the associated graph

get_mappingData_graph(self, idGraph)
get_mappingData_trace(self, idGraph, idTrace)
class HowToPlotGraph(attribute_x, attribute_y, kwargs_graph=None, excluded=None)
exclude_col(self, id_col)

Add id_col to exclude from the graph

__str__(self)
class gui_mainWindow(QtWidgetList, isLight=True, actionOnWindowClosed=None, neverCloseWindow=False, title_window='Awesome Visualisation Tool', size=None)

Bases: PyQt5.QtWidgets.QMainWindow

Main class that spawns a Qt window. Use run() to display it.

set_actionOnClose(self, actionOnWindowClosed)
closeEvent(self, event)
run(self, hold=False)

Display the window

keyPressEvent(self, event)
class widget_graphs_visual(theGraphs, **kwargs)

Bases: PyQt5.QtWidgets.QWidget

Widget element to draw a graph. The traces and graphs to draw are defined in Graphs taken as argument. This widget is linked to the excellent third-party library pyqtgraph, under MIT license

signal_must_update
signal_graph_changed
set_graph_disposition(self, indexGraph, row=1, col=1, rowspan=1, colspan=1)

Change the graphs disposition.

Parameters:
  • indexGraph – index of the graph to change
  • row – row where to place the graph
  • col – column where to place the graph
  • rowspan – number of rows across which the graph spans
  • colspan – number of columns across which the graph spans
Returns:

__create_graph(self, idGraph)
__check_graphs(self)
on_click(self, plotDataItem, clicked_points)
update_graphs(self, singleUpdate=True)

This method is used to update the graph. This is fast but NOT safe (especially when working with threads). To limit the risks, please use self.signal_must_update.emit() instead.

Parameters:singleUpdate – if set to False, the graph will periodically refres each self.refreshtime
fast_update(self)

Use this method to update the graph in a fast way. NOT THREAD SAFE.

exportGraphs(self)

Export the graphs

link_axes(self)
get_graph(self, idGraph)

Get corresponding GraphVisual of the graph idGraph

keyPressEvent(self, event)

What happens if a key is pressed. R: reset the axes to their default value

delete_graph(self, idGraph)

Delete the graph idGraph

delete(self)
get_all_graphsVisual(self)

Return a dictionary {idGraph: GraphVisual}.

get_layout_buttons(self)

Get the QGraphicsLayout where it’s possible to add buttons, etc.

set_actionOnClick(self, theActionOnClick)

Action to perform when the graph is clicked

Parameters:theActionOnClickon_graph_click_interface
Returns:
set_title(self, idGraph, titleName, **kwargs)

Set title of the graph

Parameters:
  • idGraph – id of the graph
  • titleName – title to set
set_article_template(self, graph_size_x=8.8, graph_size_y=4.4, legendPosition='NW')

Method to set the graphs to article quality graph.

Parameters:
  • graph_size_x – width of the graph in cm
  • graph_size_y – height of the graph in cm
  • legendPosition – position of the legend (NE, SE, SW, NW)
Returns:

class on_graph_click_showInfo(theLinkDataGraph, visuals=None)

Bases: optimeed.visualize.gui.widgets.widget_graphs_visual.on_graph_click_interface

On click: show informations about the points (loop through attributes)

class DataInformationVisuals
delete_visual(self, theVisual)
add_visual(self, theVisual, theTrace, indexPoint)
get_new_index(self)
curr_index(self)
graph_clicked(self, theGraphVisual, index_graph, index_trace, indices_points)

Action to perform when a point in the graph has been clicked: Creates new window displaying the device and its informations

get_name(self)
class guiPyqtgraph(graphsVisual, **kwargs)

Create a gui for pyqtgraph with trace selection options, export and action on clic choices

refreshTraceList(self)

Refresh all the traces

class OptimizationDisplayer(thePipeOpti, listOfObjectives, theOptimizer, additionalWidgets=None)

Class used to display optimization process in real time

signal_optimization_over
set_actionsOnClick(self, theList)

Set actions to perform on click, list of on_graph_click_interface

generate_optimizationGraphs(self, refresh_time=0.1)

Generates the optimization graphs. :return: Graphs, LinkDataGraph, :class:’~optimeed.visulaize.gui.widgets.widget_graphs_visual.widget_graphs_visual

create_main_window(self)

From the widgets and the actions on click, spawn a window and put a gui around widgetsGraphsVisual.

__change_appearance_violate_constraints(self)
__auto_refresh(self, refresh_time)
__set_graphs_disposition(self)

Set nicely the graphs disposition

launch_optimization(self)

Perform the optimization and spawn the convergence graphs afterwards.

__callback_optimization(self, myWindow)
class Worker

Bases: PyQt5.QtCore.QObject

signal_show_UI
display_graphs(self, theGraphs)
class widget_graphs_visual(theGraphs, **kwargs)

Bases: PyQt5.QtWidgets.QWidget

Widget element to draw a graph. The traces and graphs to draw are defined in Graphs taken as argument. This widget is linked to the excellent third-party library pyqtgraph, under MIT license

signal_must_update
signal_graph_changed
set_graph_disposition(self, indexGraph, row=1, col=1, rowspan=1, colspan=1)

Change the graphs disposition.

Parameters:
  • indexGraph – index of the graph to change
  • row – row where to place the graph
  • col – column where to place the graph
  • rowspan – number of rows across which the graph spans
  • colspan – number of columns across which the graph spans
Returns:

__create_graph(self, idGraph)
__check_graphs(self)
on_click(self, plotDataItem, clicked_points)
update_graphs(self, singleUpdate=True)

This method is used to update the graph. This is fast but NOT safe (especially when working with threads). To limit the risks, please use self.signal_must_update.emit() instead.

Parameters:singleUpdate – if set to False, the graph will periodically refres each self.refreshtime
fast_update(self)

Use this method to update the graph in a fast way. NOT THREAD SAFE.

exportGraphs(self)

Export the graphs

link_axes(self)
get_graph(self, idGraph)

Get corresponding GraphVisual of the graph idGraph

keyPressEvent(self, event)

What happens if a key is pressed. R: reset the axes to their default value

delete_graph(self, idGraph)

Delete the graph idGraph

delete(self)
get_all_graphsVisual(self)

Return a dictionary {idGraph: GraphVisual}.

get_layout_buttons(self)

Get the QGraphicsLayout where it’s possible to add buttons, etc.

set_actionOnClick(self, theActionOnClick)

Action to perform when the graph is clicked

Parameters:theActionOnClickon_graph_click_interface
Returns:
set_title(self, idGraph, titleName, **kwargs)

Set title of the graph

Parameters:
  • idGraph – id of the graph
  • titleName – title to set
set_article_template(self, graph_size_x=8.8, graph_size_y=4.4, legendPosition='NW')

Method to set the graphs to article quality graph.

Parameters:
  • graph_size_x – width of the graph in cm
  • graph_size_y – height of the graph in cm
  • legendPosition – position of the legend (NE, SE, SW, NW)
Returns:

class gui_mainWindow(QtWidgetList, isLight=True, actionOnWindowClosed=None, neverCloseWindow=False, title_window='Awesome Visualisation Tool', size=None)

Bases: PyQt5.QtWidgets.QMainWindow

Main class that spawns a Qt window. Use run() to display it.

set_actionOnClose(self, actionOnWindowClosed)
closeEvent(self, event)
run(self, hold=False)

Display the window

keyPressEvent(self, event)
start_qt_mainloop()

Starts qt mainloop, which is necessary for qt to handle events

stop_qt_mainloop()

Stops qt mainloop and resumes to program

class Data(x: list, y: list, x_label='', y_label='', legend='', is_scattered=False, transfo_x=lambda selfData, x: x, transfo_y=lambda selfData, y: y, xlim=None, ylim=None, permutations=None, sort_output=False, color=None, symbol='o', symbolsize=8, fillsymbol=True, outlinesymbol=1.8, linestyle='-', width=2)

This class is used to store informations necessary to plot a 2D graph. It has to be combined with a gui to be useful (ex. pyqtgraph)

set_data(self, x: list, y: list)

Overwrites current datapoints with new set

get_x(self)

Get x coordinates of datapoints

get_symbolsize(self)

Get size of the symbols

symbol_isfilled(self)

Check if symbols has to be filled or not

get_symbolOutline(self)

Get color factor of outline of symbols

get_length_data(self)

Get number of points

get_xlim(self)

Get x limits of viewbox

get_ylim(self)

Get y limits of viewbox

get_y(self)

Get y coordinates of datapoints

get_color(self)

Get color of the line

get_width(self)

Get width of the line

get_number_of_points(self)

Get number of points

get_plot_data(self)

Call this method to get the x and y coordinates of the points that have to be displayed. => After transformation, and after permutations.

Returns:x (list), y (list)
get_permutations(self)

Return the transformation ‘permutation’: xplot[i] = xdata[permutation[i]]

get_invert_permutations(self)

Return the inverse of permutations: xdata[i] = xplot[revert[i]]

get_dataIndex_from_graphIndex(self, index_graph_point)

From an index given in graph, recovers the index of the data.

Parameters:index_graph_point – Index in the graph
Returns:index of the data
get_dataIndices_from_graphIndices(self, index_graph_point_list)

Same as get_dataIndex_from_graphIndex but with a list in entry. Can (?) improve performances for huge dataset.

Parameters:index_graph_point_list – List of Index in the graph
Returns:List of index of the data
get_graphIndex_from_dataIndex(self, index_data)

From an index given in the data, recovers the index of the graph.

Parameters:index_data – Index in the data
Returns:index of the graph
get_graphIndices_from_dataIndices(self, index_data_list)

Same as get_graphIndex_from_dataIndex but with a list in entry. Can (?) improve performances for huge dataset.

Parameters:index_data_list – List of Index in the data
Returns:List of index of the graph
set_permutations(self, permutations)

Set permutations between datapoints of the trace

Parameters:permutations – list of indices to plot (example: [0, 2, 1] means that the first point will be plotted, then the third, then the second one)
get_x_label(self)

Get x label of the trace

get_y_label(self)

Get y label of the trace

get_legend(self)

Get name of the trace

get_symbol(self)

Get symbol

add_point(self, x, y)

Add point(s) to trace (inputs can be list or numeral)

delete_point(self, index_point)

Delete a point from the datapoints

is_scattered(self)

Delete a point from the datapoints

set_indices_points_to_plot(self, indices)

Set indices points to plot

get_indices_points_to_plot(self)

Get indices points to plot

get_linestyle(self)

Get linestyle

__str__(self)
export_str(self)

Method to save the points constituting the trace

class Graphs

Contains several Graph

updateChildren(self)
add_trace_firstGraph(self, data, updateChildren=True)

Same as add_trace, but only if graphs has only one id :param data: :param updateChildren: :return:

add_trace(self, idGraph, data, updateChildren=True)

Add a trace to the graph

Parameters:
  • idGraph – id of the graph
  • dataData
  • updateChildren – Automatically calls callback functions
Returns:

id of the created trace

remove_trace(self, idGraph, idTrace, updateChildren=True)

Remove the trace from the graph

Parameters:
  • idGraph – id of the graph
  • idTrace – id of the trace to remove
  • updateChildren – Automatically calls callback functions
get_first_graph(self)

Get id of the first graph

Returns:id of the first graph
get_graph(self, idGraph)

Get graph object at idgraph

Parameters:idGraph – id of the graph to get
Returns:Graph
get_all_graphs_ids(self)

Get all ids of the graphs

Returns:list of id graphs
get_all_graphs(self)

Get all graphs. Return dict {id: Graph}

add_graph(self, updateChildren=True)

Add a new graph

Returns:id of the created graph
remove_graph(self, idGraph)

Delete a graph

Parameters:idGraph – id of the graph to delete
add_update_method(self, childObject)

Add a callback each time a graph is modified.

Parameters:childObject – method without arguments
export_str(self)

Export all the graphs in text

Returns:str
merge(self, otherGraphs)
reset(self)
class guiPyqtgraph(graphsVisual, **kwargs)

Create a gui for pyqtgraph with trace selection options, export and action on clic choices

refreshTraceList(self)

Refresh all the traces

class PlotHolders
add_plot(self, x, y, **kwargs)
get_wgGraphs(self)
new_plot(self)
set_title(self, theTitle, **kwargs)
reset(self)
axis_equal(self)
class WindowHolders
set_currFigure(self, currFigure)
add_plot(self, *args, **kwargs)
set_title(self, *args, **kwargs)
new_figure(self)
new_plot(self)
show(self)
get_curr_plotHolder(self)
get_wgGraphs(self, fig=None)
get_all_figures(self)
axis_equal(self)
myWindows
plot(x, y, hold=False, **kwargs)

Plot new trace

show()

Show (start qt mainloop) graphs. Blocking

figure(numb)

Set current figure

new_plot()

Add new plot

set_title(theTitle, **kwargs)

Set title of the plot

axis_equal()
get_all_figures()

Get all existing figures

get_wgGraphs(fig=None)

Advanced option. :return: widget_graphs_visual