def __init__(self, templates, balance_groups=False):
self.templates = templates<EOL>self.balance_groups = balance_groups<EOL>self.__init()<EOL>
CGR standardization and reaction balancing

:param templates: CGRTemplates. list of rules for graph modifications.
:param balance_groups: if True: for unbalanced reactions contains multiple attached functional groups in
    products and one of them described in reagents - will be restored information about all equal groups.
    for example:

        R + B1-X-> B'1-R'-B'2 + X'

    where B' is transformed B, R and X same.
    we know what B'1 and B'2 is equal and B'1 is transformed B1 =>
    this groups most likely appeared from a single reagent. we can add copy of B-X to reagents.
    results will be:

        R + B1-X1 + B2-X2 -> B'1-R'-B'2 + X'1 + X'2