TheLastBen commited on
Commit
7b8cfd8
1 Parent(s): 1f8c018

Update Scripts/mainpaperspacev2.py

Browse files
Files changed (1) hide show
  1. Scripts/mainpaperspacev2.py +7 -8
Scripts/mainpaperspacev2.py CHANGED
@@ -120,8 +120,8 @@ def downloadmodel_pthv2(CKPT_Path, Custom_Model_Version):
120
  call('python convertodiffv2.py '+CKPT_Path+' stable-diffusion-custom --v2 --reference_model stabilityai/stable-diffusion-2-1-base', shell=True)
121
  elif Custom_Model_Version=='768':
122
  call('python convertodiffv2.py '+CKPT_Path+' stable-diffusion-custom --v2 --reference_model stabilityai/stable-diffusion-2-1', shell=True)
123
- if os.path.exists('stable-diffusion-custom/unet/diffusion_pytorch_model.bin'):
124
- call('wget -q -O stable-diffusion-custom/unet/config.json https://huggingface.co/stabilityai/stable-diffusion-2-1/raw/main/unet/config.json', shell=True)
125
  call('rm convertodiffv2.py', shell=True)
126
  if os.path.exists('stable-diffusion-custom/unet/diffusion_pytorch_model.bin'):
127
  os.chdir('/notebooks')
@@ -136,10 +136,9 @@ def downloadmodel_pthv2(CKPT_Path, Custom_Model_Version):
136
  print('Wrong path, use the file explorer to copy the path')
137
  os.chdir('/notebooks')
138
  time.sleep(5)
139
-
140
-
141
-
142
-
143
  def downloadmodel_lnkv2(CKPT_Link, Custom_Model_Version):
144
  import wget
145
  os.chdir('/models')
@@ -152,8 +151,8 @@ def downloadmodel_lnkv2(CKPT_Link, Custom_Model_Version):
152
  call('python convertodiffv2.py model.ckpt stable-diffusion-custom --v2 --reference_model stabilityai/stable-diffusion-2-1-base', shell=True)
153
  elif Custom_Model_Version=='768':
154
  call('python convertodiffv2.py model.ckpt stable-diffusion-custom --v2 --reference_model stabilityai/stable-diffusion-2-1', shell=True)
155
- if os.path.exists('stable-diffusion-custom/unet/diffusion_pytorch_model.bin'):
156
- call('wget -q -O stable-diffusion-custom/unet/config.json https://huggingface.co/stabilityai/stable-diffusion-2-1/raw/main/unet/config.json', shell=True)
157
  call('rm convertodiffv2.py', shell=True)
158
  if os.path.exists('stable-diffusion-custom/unet/diffusion_pytorch_model.bin'):
159
  call('rm model.ckpt', shell=True)
 
120
  call('python convertodiffv2.py '+CKPT_Path+' stable-diffusion-custom --v2 --reference_model stabilityai/stable-diffusion-2-1-base', shell=True)
121
  elif Custom_Model_Version=='768':
122
  call('python convertodiffv2.py '+CKPT_Path+' stable-diffusion-custom --v2 --reference_model stabilityai/stable-diffusion-2-1', shell=True)
123
+ #if os.path.exists('stable-diffusion-custom/unet/diffusion_pytorch_model.bin'):
124
+ #call('wget -q -O stable-diffusion-custom/unet/config.json https://huggingface.co/stabilityai/stable-diffusion-2-1/raw/main/unet/config.json', shell=True)
125
  call('rm convertodiffv2.py', shell=True)
126
  if os.path.exists('stable-diffusion-custom/unet/diffusion_pytorch_model.bin'):
127
  os.chdir('/notebooks')
 
136
  print('Wrong path, use the file explorer to copy the path')
137
  os.chdir('/notebooks')
138
  time.sleep(5)
139
+
140
+
141
+
 
142
  def downloadmodel_lnkv2(CKPT_Link, Custom_Model_Version):
143
  import wget
144
  os.chdir('/models')
 
151
  call('python convertodiffv2.py model.ckpt stable-diffusion-custom --v2 --reference_model stabilityai/stable-diffusion-2-1-base', shell=True)
152
  elif Custom_Model_Version=='768':
153
  call('python convertodiffv2.py model.ckpt stable-diffusion-custom --v2 --reference_model stabilityai/stable-diffusion-2-1', shell=True)
154
+ #if os.path.exists('stable-diffusion-custom/unet/diffusion_pytorch_model.bin'):
155
+ #call('wget -q -O stable-diffusion-custom/unet/config.json https://huggingface.co/stabilityai/stable-diffusion-2-1/raw/main/unet/config.json', shell=True)
156
  call('rm convertodiffv2.py', shell=True)
157
  if os.path.exists('stable-diffusion-custom/unet/diffusion_pytorch_model.bin'):
158
  call('rm model.ckpt', shell=True)