NagisaNao commited on
Commit
b40bc5a
·
verified ·
1 Parent(s): b9af71f

fix for preview images

Browse files
Files changed (1) hide show
  1. special/dl_display_results.py +4 -4
special/dl_display_results.py CHANGED
@@ -165,7 +165,7 @@ display(HTML(CSS))
165
  HR = widgets.HTML('<hr>')
166
 
167
  header_widget = widgets.HTML(value='''
168
- <div class="header_dl">DOWNLOAD RESULTS <span style="color: grey; opacity: 0.25;">| v0.2.6</span></div>
169
  ''')
170
 
171
  # Adding content to "outputs_widgets_list"
@@ -176,13 +176,13 @@ def output_container_generator(header, items):
176
  return container_widget
177
 
178
  # Models
179
- models_list = [file for file in os.listdir(models_dir) if not file.endswith('.txt')]
180
  models_widget = output_container_generator('Models', models_list).add_class("model")
181
  # Vaes
182
- vaes_list = [file for file in os.listdir(vaes_dir) if not file.endswith('.txt')]
183
  vaes_widget = output_container_generator('VAEs', vaes_list).add_class("vae")
184
  # Embeddings
185
- embeddings_list = [file for file in os.listdir(embeddings_dir) if not file.endswith('.txt') and not os.path.isdir(os.path.join(embeddings_dir, file))]
186
  embeddings_widget = output_container_generator('Embeddings', embeddings_list).add_class("embedding")
187
  # LoRAs
188
  # loras_list = [file for file in os.listdir(loras_dir) if not file.endswith('.txt')]
 
165
  HR = widgets.HTML('<hr>')
166
 
167
  header_widget = widgets.HTML(value='''
168
+ <div class="header_dl">DOWNLOAD RESULTS <span style="color: grey; opacity: 0.25;">| v0.2.7</span></div>
169
  ''')
170
 
171
  # Adding content to "outputs_widgets_list"
 
176
  return container_widget
177
 
178
  # Models
179
+ models_list = [file for file in os.listdir(models_dir) if file.endswith('.safetensors')]
180
  models_widget = output_container_generator('Models', models_list).add_class("model")
181
  # Vaes
182
+ vaes_list = [file for file in os.listdir(vaes_dir) if file.endswith('.safetensors')]
183
  vaes_widget = output_container_generator('VAEs', vaes_list).add_class("vae")
184
  # Embeddings
185
+ embeddings_list = [file for file in os.listdir(embeddings_dir) if file.endswith(('.safetensors', '.pt')) and not os.path.isdir(os.path.join(embeddings_dir, file))]
186
  embeddings_widget = output_container_generator('Embeddings', embeddings_list).add_class("embedding")
187
  # LoRAs
188
  # loras_list = [file for file in os.listdir(loras_dir) if not file.endswith('.txt')]