def check_is_number(string):
    """
    Check if the given string a number.
    """
    try:
        float(string.replace(',', ''))
        return True
    except ValueError:
        # check if there's comma inside
        return False

    Check if the given string a number.
    
internvl_chat/eval/mmmu/eval_utils.py