游雁
2024-06-24 1596f6f414f6f41da66506debb1dff19fffeb3ec
funasr/auto/auto_model.py
@@ -92,7 +92,8 @@
                if isinstance(data_i, str) and os.path.exists(data_i):
                    key = misc.extract_filename_without_extension(data_i)
                else:
                    key = "rand_key_" + "".join(random.choice(chars) for _ in range(13))
                    if key is None:
                        key = "rand_key_" + "".join(random.choice(chars) for _ in range(13))
                key_list.append(key)
    else:  # raw text; audio sample point, fbank; bytes
@@ -110,6 +111,13 @@
    def __init__(self, **kwargs):
        try:
            from funasr.utils.version_checker import check_for_update
            check_for_update()
        except:
            pass
        log_level = getattr(logging, kwargs.get("log_level", "INFO").upper())
        logging.basicConfig(level=log_level)