def SetCardCounter(self): cards = Cards() card_list = cards.GetCards() counter = [ card for card in card_list if card.index not in [x.index for x in self.cards] ] self.CardCounter.SetCardData(counter) self.CardCounter.ParseHandCardData()