piyk commited on
Commit
c094310
·
verified ·
1 Parent(s): 4cf1558

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -0
app.py CHANGED
@@ -12,6 +12,8 @@ import torch
12
  from diffusers import DiffusionPipeline
13
 
14
  DESCRIPTION = """# Playground v2.5"""
 
 
15
 
16
  MAX_SEED = np.iinfo(np.int32).max
17
  CACHE_EXAMPLES = torch.cuda.is_available() and os.getenv("CACHE_EXAMPLES", "1") == "1"
 
12
  from diffusers import DiffusionPipeline
13
 
14
  DESCRIPTION = """# Playground v2.5"""
15
+ if not torch.cuda.is_available():
16
+ DESCRIPTION += "\n<p>Running on CPU 🥶 This demo may not work on CPU.</p>"
17
 
18
  MAX_SEED = np.iinfo(np.int32).max
19
  CACHE_EXAMPLES = torch.cuda.is_available() and os.getenv("CACHE_EXAMPLES", "1") == "1"