diff --git a/tdm_loader/tdm_loader.py b/tdm_loader/tdm_loader.py index 707f554..4c39e19 100644 --- a/tdm_loader/tdm_loader.py +++ b/tdm_loader/tdm_loader.py @@ -199,8 +199,10 @@ def channel_group_search(self, search_term): ind = [] for name in found_terms: - i = chg_names.index(name) - ind.append((name, i)) + for occurence in range(found_terms.count(name)): + i = self.channel_group_index(name, occurence) + if (name, i) not in ind: + ind.append((name, i)) return ind