kael558 commited on
Commit
e224f46
·
1 Parent(s): 837d75b

cpu only sd

Browse files
Files changed (2) hide show
  1. app.py +1 -0
  2. sd.py +2 -2
app.py CHANGED
@@ -41,6 +41,7 @@ def generate_drawing(text):
41
  args = clone_args()
42
  args.seed = random.randint(0, 2**32 - 1)
43
  args.prompt = text
 
44
  results = sd.generate(args, return_c=True)
45
  c, image = results[0], results[1]
46
  size = c.size()
 
41
  args = clone_args()
42
  args.seed = random.randint(0, 2**32 - 1)
43
  args.prompt = text
44
+ print("Generating image... with text: " + str(text))
45
  results = sd.generate(args, return_c=True)
46
  c, image = results[0], results[1]
47
  size = c.size()
sd.py CHANGED
@@ -22,7 +22,7 @@ from omegaconf import OmegaConf
22
  from huggingface_hub import hf_hub_download
23
 
24
  # 1. Download stable diffusion repository and set path
25
- os.system("git clone https://github.com/kael558/stable-diffusion")
26
  os.system("git clone https://github.com/shariqfarooq123/AdaBins.git")
27
  os.system("git clone https://github.com/isl-org/MiDaS.git")
28
  os.system("git clone https://github.com/MSFTserver/pytorch3d-lite.git")
@@ -34,7 +34,7 @@ with open('k-diffusion/k_diffusion/__init__.py', 'w') as f:
34
  sys.path.extend([
35
  './taming-transformers',
36
  './clip',
37
- 'stable-diffusion/',
38
  'k-diffusion',
39
  'pytorch3d-lite',
40
  'AdaBins',
 
22
  from huggingface_hub import hf_hub_download
23
 
24
  # 1. Download stable diffusion repository and set path
25
+ os.system("git clone https://github.com/darkhemic/stable-diffusion-cpuonly")
26
  os.system("git clone https://github.com/shariqfarooq123/AdaBins.git")
27
  os.system("git clone https://github.com/isl-org/MiDaS.git")
28
  os.system("git clone https://github.com/MSFTserver/pytorch3d-lite.git")
 
34
  sys.path.extend([
35
  './taming-transformers',
36
  './clip',
37
+ 'stable-diffusion-cpuonly',
38
  'k-diffusion',
39
  'pytorch3d-lite',
40
  'AdaBins',