imod.viewers.views_tkinter_tree module

class imod.viewers.views_tkinter_tree.ImodGenericTreeProvider(protocol, objs, isInteractive=False)[source]

Bases: pyworkflow.gui.tree.TreeProvider

Model class that will retrieve the information from TiltSeries, Tomogram, SetOfTomograms, SetOfTiltSeries and prepare the columns/rows models required by the TreeDialog GUI.

COL_ALIGNED = 'Aligned'
COL_COOR3D = 'Coordinates 3D'
COL_INFO = 'Info'
COL_LANDMODEL_NO_GAPS = 'Landmark models no gaps'
COL_PREALIGNED = 'Prealigned'
COL_RECONST_TOMOGRAM = 'Full tomograms'
COL_STATUS = 'Status'
COL_TS = 'Tilt series'
ORDER_DICT = {'Tilt series': 'id'}

Configure the available tags in the tree that will be setup later for each item in the tree. :returns: * Nothing

  • Adds tags to the tree for customizing


Return a list of tuples (c, w) where: c: is the column name and index w: is the column width

getImodCTFEstimationColumnValues(obj, values)[source]
getImodEtomoColumnValues(obj, values)[source]
getObjStatus(obj, values)[source]

Return a list of tuples (key, action) were keys are the string options that will be display in the context menu and the actions are the functions to call when the specific action is selected. The first action in the list will be taken as the default one when the element is double-clicked.


This function will be called by the Tree with each object that will be inserted. A dictionary should be returned with the possible following entries: ‘key’: the key value to insert in the Tree ‘text’: text of the object to be displayed

(if not passed the ‘key’ will be used)

‘image’: image path to be displayed as icon (optional) ‘parent’: the object’s parent in which insert this object (optional) ‘tags’: list of tags names (optional)


Return the objects that will be inserted in the Tree


Check if an object is selected or not.

class imod.viewers.views_tkinter_tree.ImodGenericViewer(parent, protocol, objs, displayAllButton=True, createSetButton=False, isInteractive=False, itemDoubleClick=False, **kwargs)[source]

Bases: pyworkflow.viewer.View

This class implements a view using Tkinter ListDialog and the ImodTreeProvider.


This method should be overwritten to implement how this particular view will be displayed in desktop.

class imod.viewers.views_tkinter_tree.ImodListDialog(parent, title, provider, displayAllButton=True, createSetButton=False, itemDoubleClick=False, **kwargs)[source]

Bases: pyworkflow.gui.dialog.ListDialog


create dialog body. return widget that should have initial focus. This method should be overridden, and is called by the __init__ method.

class imod.viewers.views_tkinter_tree.ImodSetOfLandmarkModelsView(set, **kwargs)[source]

Bases: pyworkflow.viewer.CommandView

Wrapper to visualize landmark models with 3dmod

class imod.viewers.views_tkinter_tree.ImodSetOfTomogramsView(set, **kwargs)[source]

Bases: pyworkflow.viewer.CommandView

Wrapper to visualize set of tomograms with 3dmod

class imod.viewers.views_tkinter_tree.ImodSetView(set, **kwargs)[source]

Bases: pyworkflow.viewer.CommandView

Wrapper to visualize different type of objects with the 3dmod

class imod.viewers.views_tkinter_tree.protClass[source]

Bases: object

protImodCTFEstimation = 2
protImodEtomoClass = 1