Convert string to string, integer, or float. Support tuple or list.

        Examples:
            >>> StringClass.convert_str2num('1.23')
            1.23
            >>> StringClass.convert_str2num(u'1.23')
            1.23
            >>> StringClass.convert_str2num(u'21.')
            21
            >>> StringClass.convert_str2num('abc123')
            'abc123'
            >>> StringClass.convert_str2num((123, u'2.3', 3., 'abc', u'edf'))
            (123, 2.3, 3, 'abc', 'edf')
            >>> StringClass.convert_str2num([123, u'2.3', 3., 'abc', u'edf'])
            [123, 2.3, 3, 'abc', 'edf']

def convert_str2num(unicode_str  # type: Union[AnyStr, int, float, List[Union[AnyStr, float, int]], Tuple[Union[AnyStr, float, int]]]
                        ):
        # type: (...) -> Union[AnyStr, int, float, List[Union[AnyStr, float, int]], Tuple[Union[AnyStr, float, int]]]
        """Convert string to string, integer, or float. Support tuple or list.

        Examples:
            >>> StringClass.convert_str2num('1.23')
            1.23
            >>> StringClass.convert_str2num(u'1.23')
            1.23
            >>> StringClass.convert_str2num(u'21.')
            21
            >>> StringClass.convert_str2num('abc123')
            'abc123'
            >>> StringClass.convert_str2num((123, u'2.3', 3., 'abc', u'edf'))
            (123, 2.3, 3, 'abc', 'edf')
            >>> StringClass.convert_str2num([123, u'2.3', 3., 'abc', u'edf'])
            [123, 2.3, 3, 'abc', 'edf']
        """
        if MathClass.isnumerical(unicode_str):
            unicode_str = float(unicode_str)
            if unicode_str % 1. == 0.:
                unicode_str = int(unicode_str)
            return unicode_str
        elif is_string(unicode_str):
            return str(unicode_str)
        elif isinstance(unicode_str, tuple):
            return tuple(StringClass.convert_str2num(v) for v in unicode_str)
        elif isinstance(unicode_str, list):
            return list(StringClass.convert_str2num(v) for v in unicode_str)
        else:
            return unicode_str