Skip to content

Commit 447ccd0

Browse files
authored
Set _torch_version to N/A if torch is disabled. (#11645)
1 parent f3e0911 commit 447ccd0

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/diffusers/utils/import_utils.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -99,6 +99,7 @@ def _is_package_available(pkg_name: str, get_dist_name: bool = False) -> Tuple[b
9999
else:
100100
logger.info("Disabling PyTorch because USE_TORCH is set")
101101
_torch_available = False
102+
_torch_version = "N/A"
102103

103104
_jax_version = "N/A"
104105
_flax_version = "N/A"

0 commit comments

Comments
 (0)