────────────────────────────── Traceback (most recent call last) ────────────────────────────────╮ │ /workspace/SUPIR/gradio_demo.py:47 in │ │ │ │ 44 │ raise ValueError('Currently support CUDA only.') │ │ 45 │ │ 46 # load SUPIR │ │ ❱ 47 model = create_SUPIR_model('options/SUPIR_v0.yaml', SUPIR_sign='Q') │ │ 48 #args.loading_half_params=True │ │ 49 #args.use_tile_vae=True │ │ 50 if args.loading_half_params: │ │ │ │ /workspace/SUPIR/SUPIR/util.py:36 in create_SUPIR_model │ │ │ │ 33 │ │ 34 def create_SUPIR_model(config_path, SUPIR_sign=None): │ │ 35 │ config = OmegaConf.load(config_path) │ │ ❱ 36 │ model = instantiate_from_config(config.model).cpu() │ │ 37 │ print(f'Loaded model config from [{config_path}]') │ │ 38 │ if config.SDXL_CKPT is not None: │ │ 39 │ │ model.load_state_dict(load_state_dict(config.SDXL_CKPT), strict=False) │ │ │ │ /workspace/SUPIR/sgm/util.py:175 in instantiate_from_config │ │ │ │ 172 │ │ elif config == "__is_unconditional__": │ │ 173 │ │ │ return None │ │ 174 │ │ raise KeyError("Expected key `target` to instantiate.") │ │ ❱ 175 │ return get_obj_from_str(config["target"])(**config.get("params", dict())) │ │ 176 │ │ 177 │ │ 178 def get_obj_from_str(string, reload=False, invalidate_cache=True): │ │ │ │ /workspace/SUPIR/SUPIR/models/SUPIR_model.py:14 in __init__ │ │ │ │ 11 │ │ 12 class SUPIRModel(DiffusionEngine): │ │ 13 │ def __init__(self, control_stage_config, ae_dtype='fp32', diffusion_dtype='fp32', p_ │ │ ❱ 14 │ │ super().__init__(*args, **kwargs) │ │ 15 │ │ control_model = instantiate_from_config(control_stage_config) │ │ 16 │ │ self.model.load_control_model(control_model) │ │ 17 │ │ self.first_stage_model.denoise_encoder = copy.deepcopy(self.first_stage_model.en │ │ │ │ /workspace/SUPIR/sgm/models/diffusion.py:61 in __init__ │ │ │ │ 58 │ │ │ if sampler_config is not None │ │ 59 │ │ │ else None │ │ 60 │ │ ) │ │ ❱ 61 │ │ self.conditioner = instantiate_from_config( │ │ 62 │ │ │ default(conditioner_config, UNCONDITIONAL_CONFIG) │ │ 63 │ │ ) │ │ 64 │ │ self.scheduler_config = scheduler_config │ │ │ │ /workspace/SUPIR/sgm/util.py:175 in instantiate_from_config │ │ │ │ 172 │ │ elif config == "__is_unconditional__": │ │ 173 │ │ │ return None │ │ 174 │ │ raise KeyError("Expected key `target` to instantiate.") │ │ ❱ 175 │ return get_obj_from_str(config["target"])(**config.get("params", dict())) │ │ 176 │ │ 177 │ │ 178 def get_obj_from_str(string, reload=False, invalidate_cache=True): │ │ │ │ /workspace/SUPIR/sgm/modules/encoders/modules.py:89 in __init__ │ │ │ │ 86 │ │ super().__init__() │ │ 87 │ │ embedders = [] │ │ 88 │ │ for n, embconfig in enumerate(emb_models): │ │ ❱ 89 │ │ │ embedder = instantiate_from_config(embconfig) │ │ 90 │ │ │ assert isinstance( │ │ 91 │ │ │ │ embedder, AbstractEmbModel │ │ 92 │ │ │ ), f"embedder model {embedder.__class__.__name__} has to inherit from Abstra │ │ │ │ /workspace/SUPIR/sgm/util.py:175 in instantiate_from_config │ │ │ │ 172 │ │ elif config == "__is_unconditional__": │ │ 173 │ │ │ return None │ │ 174 │ │ raise KeyError("Expected key `target` to instantiate.") │ │ ❱ 175 │ return get_obj_from_str(config["target"])(**config.get("params", dict())) │ │ 176 │ │ 177 │ │ 178 def get_obj_from_str(string, reload=False, invalidate_cache=True): │ │ │ │ /workspace/SUPIR/sgm/modules/encoders/modules.py:462 in __init__ │ │ │ │ 459 │ ): # clip-vit-base-patch32 │ │ 460 │ │ super().__init__() │ │ 461 │ │ assert layer in self.LAYERS │ │ ❱ 462 │ │ self.tokenizer = CLIPTokenizer.from_pretrained(version if SDXL_CLIP1_PATH is Non │ │ 463 │ │ self.transformer = CLIPTextModel.from_pretrained(version if SDXL_CLIP1_PATH is N │ │ 464 │ │ self.device = device │ │ 465 │ │ self.max_length = max_length │ │ │ │ /workspace/SUPIR/venv/lib/python3.10/site-packages/transformers/tokenization_utils_base.py:1811 │ │ in from_pretrained │ │ │ │ 1808 │ │ │ else: │ │ 1809 │ │ │ │ logger.info(f"loading file {file_path} from cache at {resolved_vocab_fil │ │ 1810 │ │ │ │ ❱ 1811 │ │ return cls._from_pretrained( │ │ 1812 │ │ │ resolved_vocab_files, │ │ 1813 │ │ │ pretrained_model_name_or_path, │ │ 1814 │ │ │ init_configuration, │ │ │ │ /workspace/SUPIR/venv/lib/python3.10/site-packages/transformers/tokenization_utils_base.py:1965 │ │ in _from_pretrained │ │ │ │ 1962 │ │ │ │ 1963 │ │ # Instantiate tokenizer. │ │ 1964 │ │ try: │ │ ❱ 1965 │ │ │ tokenizer = cls(*init_inputs, **init_kwargs) │ │ 1966 │ │ except OSError: │ │ 1967 │ │ │ raise OSError( │ │ 1968 │ │ │ │ "Unable to load vocabulary from file. " │ │ │ │ /workspace/SUPIR/venv/lib/python3.10/site-packages/transformers/models/clip/tokenization_clip.py │ │ :322 in __init__ │ │ │ │ 319 │ │ │ self.nlp = BasicTokenizer(do_lower_case=True) │ │ 320 │ │ │ self.fix_text = None │ │ 321 │ │ │ │ ❱ 322 │ │ with open(vocab_file, encoding="utf-8") as vocab_handle: │ │ 323 │ │ │ self.encoder = json.load(vocab_handle) │ │ 324 │ │ self.decoder = {v: k for k, v in self.encoder.items()} │ │ 325 │ │ self.errors = errors # how to handle errors in decoding │ ╰──────────────────────────────────────────────────────────────────────────────────────────────────╯ TypeError: expected str, bytes or os.PathLike object, not NoneType