Skip to content

Commit

Permalink
Merge pull request #16169 from AUTOMATIC1111/py-3.9-compatibility
Browse files Browse the repository at this point in the history
Py 3.9 compatibility
  • Loading branch information
AUTOMATIC1111 authored Jul 8, 2024
2 parents 1da4907 + c3d8b78 commit bad47dc
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
1 change: 1 addition & 0 deletions extensions-builtin/Lora/networks.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
from __future__ import annotations
import gradio as gr
import logging
import os
Expand Down
9 changes: 4 additions & 5 deletions scripts/xyz_grid.py
Original file line number Diff line number Diff line change
Expand Up @@ -118,11 +118,10 @@ def apply_size(p, x: str, xs) -> None:


def find_vae(name: str):
match name := name.lower().strip():
case 'auto', 'automatic':
return 'Automatic'
case 'none':
return 'None'
if name := name.strip().lower() in ('auto', 'automatic'):
return 'Automatic'
elif name == 'none':
return 'None'
return next((k for k in modules.sd_vae.vae_dict if k.lower() == name), print(f'No VAE found for {name}; using Automatic') or 'Automatic')


Expand Down

0 comments on commit bad47dc

Please sign in to comment.