aky15
2023-04-12 28a19dbc4e85d3b8a4ec2ef7483bba64d422b43f
funasr/tasks/abs_task.py
@@ -1582,10 +1582,11 @@
    ) -> AbsIterFactory:
        assert check_argument_types()
        if args.frontend_conf is not None and "fs" in args.frontend_conf:
            dest_sample_rate = args.frontend_conf["fs"]
        else:
            dest_sample_rate = 16000
        if hasattr(args, "frontend_conf"):
            if args.frontend_conf is not None and "fs" in args.frontend_conf:
                dest_sample_rate = args.frontend_conf["fs"]
            else:
                dest_sample_rate = 16000
        dataset = ESPnetDataset(
            iter_options.data_path_and_name_and_type,
@@ -1593,7 +1594,11 @@
            preprocess=iter_options.preprocess_fn,
            max_cache_size=iter_options.max_cache_size,
            max_cache_fd=iter_options.max_cache_fd,
<<<<<<< HEAD
            dest_sample_rate=args.frontend_conf["fs"] if args.frontend_conf else 16000,
=======
            dest_sample_rate=dest_sample_rate,
>>>>>>> main
        )
        cls.check_task_requirements(
            dataset, args.allow_variable_data_keys, train=iter_options.train