<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def count_mnemonic(self, mnemonic, uwis=uwis, alias=None):
 """ Counts the wells that have a given curve, given the mnemonic and an alias dict. """

        all_mnemonics = self.get_mnemonics([mnemonic], uwis=uwis, alias=alias)
        return len(list(filter(None, utils.flatten_list(all_mnemonics))))