INNER CODE UNIT · Python
Graph
steineggerlab/Metabuli · util/gtdb_to_taxdump.py:54
class Graph(object):
def __init__(self, graph_dict=None):
""" initializes a graph object
If no dictionary or None is given,
an empty dictionary will be used
"""
self.__ranks = {'d__' : 'superkingdom',
'p__' : 'phylum',
'c__' : 'class',
'o__' : 'order',
'f__' : 'family',
'g__' : 'genus',
's__' : 'species'}
if graph_dict == None:
graph_dict = {}
self.__graph_dict = graph_dict
self.__graph_nodeIDs = {}