Skip to content

Commit bce36d2

Browse files
authored
Fix model caching for diffusion models and multiple GPUs (huggingface#665)
1 parent ff5d185 commit bce36d2

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

optimum/intel/openvino/modeling_diffusion.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -671,7 +671,7 @@ def _compile(self):
671671
if (
672672
"CACHE_DIR" not in self.ov_config.keys()
673673
and not str(self._model_dir).startswith(gettempdir())
674-
and self.device.lower().split(":")[0] == "gpu"
674+
and "gpu" in self.device.lower()
675675
):
676676
self.ov_config["CACHE_DIR"] = os.path.join(self._model_dir, self._model_name, "model_cache")
677677

0 commit comments

Comments
 (0)