mirror of https://github.com/vladmandic/automatic
update constraints, patch loader and create ext exclude list
Signed-off-by: vladmandic <mandic00@live.com>pull/4713/head
parent
48e8b3a513
commit
397631fb4c
|
|
@ -1,8 +1,8 @@
|
||||||
# Change Log for SD.Next
|
# Change Log for SD.Next
|
||||||
|
|
||||||
## Update for 2026-03-25
|
## Update for 2026-03-26
|
||||||
|
|
||||||
### Highlights for 2026-03-25
|
### Highlights for 2026-03-26
|
||||||
|
|
||||||
This release brings massive code refactoring to modernize codebase and removal of some obsolete features. Leaner & Faster!
|
This release brings massive code refactoring to modernize codebase and removal of some obsolete features. Leaner & Faster!
|
||||||
And since its a bit quieter period when it comes to new models, notable additions would be : *FireRed-Image-Edit* *SkyWorks-UniPic-3* and new *Anima-Preview*
|
And since its a bit quieter period when it comes to new models, notable additions would be : *FireRed-Image-Edit* *SkyWorks-UniPic-3* and new *Anima-Preview*
|
||||||
|
|
@ -18,7 +18,7 @@ But also many smaller quality-of-life improvements - for full details, see [Chan
|
||||||
|
|
||||||
[ReadMe](https://github.com/vladmandic/automatic/blob/master/README.md) | [ChangeLog](https://github.com/vladmandic/automatic/blob/master/CHANGELOG.md) | [Docs](https://vladmandic.github.io/sdnext-docs/) | [WiKi](https://github.com/vladmandic/automatic/wiki) | [Discord](https://discord.com/invite/sd-next-federal-batch-inspectors-1101998836328697867) | [Sponsor](https://github.com/sponsors/vladmandic)
|
[ReadMe](https://github.com/vladmandic/automatic/blob/master/README.md) | [ChangeLog](https://github.com/vladmandic/automatic/blob/master/CHANGELOG.md) | [Docs](https://vladmandic.github.io/sdnext-docs/) | [WiKi](https://github.com/vladmandic/automatic/wiki) | [Discord](https://discord.com/invite/sd-next-federal-batch-inspectors-1101998836328697867) | [Sponsor](https://github.com/sponsors/vladmandic)
|
||||||
|
|
||||||
### Details for 2026-03-25
|
### Details for 2026-03-26
|
||||||
|
|
||||||
- **Models**
|
- **Models**
|
||||||
- [Google Flash 3.1 Image](https://ai.google.dev/gemini-api/docs/models/gemini-3-flash-preview) a.k.a. *Nano Banana 2*
|
- [Google Flash 3.1 Image](https://ai.google.dev/gemini-api/docs/models/gemini-3-flash-preview) a.k.a. *Nano Banana 2*
|
||||||
|
|
@ -110,6 +110,7 @@ But also many smaller quality-of-life improvements - for full details, see [Chan
|
||||||
these are now installed on-demand when needed
|
these are now installed on-demand when needed
|
||||||
- bump `huggingface_hub==1.5.0`
|
- bump `huggingface_hub==1.5.0`
|
||||||
- bump `transformers==5.3.0`
|
- bump `transformers==5.3.0`
|
||||||
|
- installer introduce `constraints.txt`
|
||||||
- refactor to/from *image/tensor* logic
|
- refactor to/from *image/tensor* logic
|
||||||
- refactor reorganize `cli` scripts
|
- refactor reorganize `cli` scripts
|
||||||
- refactor move tests to dedicated `/test/`
|
- refactor move tests to dedicated `/test/`
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,3 @@
|
||||||
|
fastapi==0.124.4
|
||||||
|
numpy==2.1.2
|
||||||
|
Pillow==10.4.0
|
||||||
|
|
@ -1263,6 +1263,7 @@ def set_environment():
|
||||||
os.environ.setdefault('MIOPEN_FIND_MODE', '2')
|
os.environ.setdefault('MIOPEN_FIND_MODE', '2')
|
||||||
os.environ.setdefault('UR_L0_ENABLE_RELAXED_ALLOCATION_LIMITS', '1')
|
os.environ.setdefault('UR_L0_ENABLE_RELAXED_ALLOCATION_LIMITS', '1')
|
||||||
os.environ.setdefault('USE_TORCH', '1')
|
os.environ.setdefault('USE_TORCH', '1')
|
||||||
|
os.environ.setdefault('UV_CONSTRAINT', os.path.abspath('constraints.txt'))
|
||||||
os.environ.setdefault('UV_INDEX_STRATEGY', 'unsafe-any-match')
|
os.environ.setdefault('UV_INDEX_STRATEGY', 'unsafe-any-match')
|
||||||
os.environ.setdefault('UV_NO_BUILD_ISOLATION', '1')
|
os.environ.setdefault('UV_NO_BUILD_ISOLATION', '1')
|
||||||
os.environ.setdefault('UVICORN_TIMEOUT_KEEP_ALIVE', '60')
|
os.environ.setdefault('UVICORN_TIMEOUT_KEEP_ALIVE', '60')
|
||||||
|
|
|
||||||
|
|
@ -64,6 +64,13 @@ def temp_disable_extensions():
|
||||||
'a1111-sd-webui-lycoris',
|
'a1111-sd-webui-lycoris',
|
||||||
'sd-webui-animatediff',
|
'sd-webui-animatediff',
|
||||||
]
|
]
|
||||||
|
disable_obsolete = [
|
||||||
|
'Lora',
|
||||||
|
'stable-diffusion-webui-rembg',
|
||||||
|
'sd-extension-framepack',
|
||||||
|
'sd-extension-nudenet',
|
||||||
|
'sd-extension-promptgen',
|
||||||
|
]
|
||||||
disable_themes = [
|
disable_themes = [
|
||||||
'sd-webui-lobe-theme',
|
'sd-webui-lobe-theme',
|
||||||
'cozy-nest',
|
'cozy-nest',
|
||||||
|
|
@ -113,7 +120,9 @@ def temp_disable_extensions():
|
||||||
for ext in disable_diffusers:
|
for ext in disable_diffusers:
|
||||||
if ext.lower() not in shared.opts.disabled_extensions:
|
if ext.lower() not in shared.opts.disabled_extensions:
|
||||||
disabled.append(ext)
|
disabled.append(ext)
|
||||||
disabled.append('Lora')
|
for ext in disable_obsolete:
|
||||||
|
if ext.lower() not in shared.opts.disabled_extensions:
|
||||||
|
disabled.append(ext)
|
||||||
|
|
||||||
shared.cmd_opts.controlnet_loglevel = 'WARNING'
|
shared.cmd_opts.controlnet_loglevel = 'WARNING'
|
||||||
return disabled
|
return disabled
|
||||||
|
|
|
||||||
|
|
@ -17,6 +17,12 @@ logging.getLogger("DeepSpeed").disabled = True
|
||||||
timer.startup.record("loader")
|
timer.startup.record("loader")
|
||||||
log.debug('Initializing: libraries')
|
log.debug('Initializing: libraries')
|
||||||
|
|
||||||
|
def report(msg: str, e: Exception):
|
||||||
|
log.error(f'Loader: {msg} {e}')
|
||||||
|
log.error('Please restart the app to fix this issue')
|
||||||
|
sys.exit(1)
|
||||||
|
|
||||||
|
|
||||||
np = None
|
np = None
|
||||||
try:
|
try:
|
||||||
os.environ.setdefault('NEP50_DISABLE_WARNING', '1')
|
os.environ.setdefault('NEP50_DISABLE_WARNING', '1')
|
||||||
|
|
@ -33,19 +39,17 @@ try:
|
||||||
return x
|
return x
|
||||||
return npwarn_decorator
|
return npwarn_decorator
|
||||||
np._no_nep50_warning = getattr(np, '_no_nep50_warning', dummy_npwarn_decorator_factory) # pylint: disable=protected-access
|
np._no_nep50_warning = getattr(np, '_no_nep50_warning', dummy_npwarn_decorator_factory) # pylint: disable=protected-access
|
||||||
|
else:
|
||||||
|
log.warning(f'Loader: numpy=={np.__version__} unsupported')
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
log.error(f'Loader: numpy=={np.__version__ if np is not None else None} {e}')
|
report(f'numpy=={np.__version__ if np is not None else None}', e)
|
||||||
log.error('Please restart the app to fix this issue')
|
|
||||||
sys.exit(1)
|
|
||||||
timer.startup.record("numpy")
|
timer.startup.record("numpy")
|
||||||
|
|
||||||
scipy = None
|
scipy = None
|
||||||
try:
|
try:
|
||||||
import scipy # pylint: disable=W0611,C0411
|
import scipy # pylint: disable=W0611,C0411
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
log.error(f'Loader: scipy=={scipy.__version__ if scipy is not None else None} {e}')
|
report(f'scipy=={scipy.__version__ if scipy is not None else None}', e)
|
||||||
log.error('Please restart the app to fix this issue')
|
|
||||||
sys.exit(1)
|
|
||||||
timer.startup.record("scipy")
|
timer.startup.record("scipy")
|
||||||
|
|
||||||
try:
|
try:
|
||||||
|
|
@ -59,13 +63,15 @@ import torch # pylint: disable=C0411
|
||||||
if torch.__version__.startswith('2.5.0'):
|
if torch.__version__.startswith('2.5.0'):
|
||||||
log.warning(f'Disabling cuDNN for SDP on torch={torch.__version__}')
|
log.warning(f'Disabling cuDNN for SDP on torch={torch.__version__}')
|
||||||
torch.backends.cuda.enable_cudnn_sdp(False)
|
torch.backends.cuda.enable_cudnn_sdp(False)
|
||||||
|
|
||||||
try:
|
try:
|
||||||
import intel_extension_for_pytorch as ipex # pylint: disable=import-error,unused-import
|
import intel_extension_for_pytorch as ipex # pylint: disable=import-error,unused-import
|
||||||
log.debug(f'Load IPEX=={ipex.__version__}')
|
log.debug(f'Load IPEX=={ipex.__version__}')
|
||||||
except Exception:
|
except Exception:
|
||||||
pass
|
pass
|
||||||
|
|
||||||
try:
|
try:
|
||||||
pass # pylint: disable=unused-import,ungrouped-imports
|
import torch.distributed.distributed_c10d as _c10d # pylint: disable=unused-import,ungrouped-imports
|
||||||
except Exception:
|
except Exception:
|
||||||
log.warning('Loader: torch is not built with distributed support')
|
log.warning('Loader: torch is not built with distributed support')
|
||||||
|
|
||||||
|
|
@ -86,11 +92,10 @@ warnings.filterwarnings(action="ignore", category=UserWarning, module="torchvisi
|
||||||
torchvision = None
|
torchvision = None
|
||||||
try:
|
try:
|
||||||
import torchvision # pylint: disable=W0611,C0411
|
import torchvision # pylint: disable=W0611,C0411
|
||||||
|
import pytorch_lightning # pytorch_lightning should be imported after torch, but it re-enables warnings on import so import once to disable them # pylint: disable=W0611,C0411
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
log.error(f'Loader: torchvision=={torchvision.__version__ if "torchvision" in sys.modules else None} {e}')
|
report(f'torchvision=={torchvision.__version__ if torchvision is not None else None}', e)
|
||||||
if '_no_nep' in str(e):
|
|
||||||
log.error('Loaded versions of packaged are not compatible')
|
|
||||||
log.error('Please restart the app to fix this issue')
|
|
||||||
logging.getLogger("xformers").addFilter(lambda record: 'A matching Triton is not available' not in record.getMessage())
|
logging.getLogger("xformers").addFilter(lambda record: 'A matching Triton is not available' not in record.getMessage())
|
||||||
logging.getLogger("pytorch_lightning").disabled = True
|
logging.getLogger("pytorch_lightning").disabled = True
|
||||||
warnings.filterwarnings(action="ignore", category=DeprecationWarning)
|
warnings.filterwarnings(action="ignore", category=DeprecationWarning)
|
||||||
|
|
@ -111,6 +116,7 @@ try:
|
||||||
torch._dynamo.config.suppress_errors = not _compile_debug # pylint: disable=protected-access
|
torch._dynamo.config.suppress_errors = not _compile_debug # pylint: disable=protected-access
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
log.warning(f'Torch logging: {e}')
|
log.warning(f'Torch logging: {e}')
|
||||||
|
|
||||||
if ".dev" in torch.__version__ or "+git" in torch.__version__:
|
if ".dev" in torch.__version__ or "+git" in torch.__version__:
|
||||||
torch.__long_version__ = torch.__version__
|
torch.__long_version__ = torch.__version__
|
||||||
torch.__version__ = re.search(r'[\d.]+[\d]', torch.__version__).group(0)
|
torch.__version__ = re.search(r'[\d.]+[\d]', torch.__version__).group(0)
|
||||||
|
|
@ -123,15 +129,28 @@ except Exception:
|
||||||
_bnb = False
|
_bnb = False
|
||||||
timer.startup.record("bnb")
|
timer.startup.record("bnb")
|
||||||
|
|
||||||
import huggingface_hub # pylint: disable=W0611,C0411
|
huggingface_hub = None
|
||||||
logging.getLogger("huggingface_hub.file_download").setLevel(logging.ERROR)
|
try:
|
||||||
logging.getLogger("huggingface_hub.utils._http").setLevel(logging.ERROR)
|
import huggingface_hub # pylint: disable=W0611,C0411
|
||||||
timer.startup.record("hfhub")
|
logging.getLogger("huggingface_hub.file_download").setLevel(logging.ERROR)
|
||||||
|
logging.getLogger("huggingface_hub.utils._http").setLevel(logging.ERROR)
|
||||||
|
timer.startup.record("hfhub")
|
||||||
|
except Exception as e:
|
||||||
|
report(f'huggingface_hub=={huggingface_hub.__version__ if "huggingface_hub" in sys.modules else None}', e)
|
||||||
|
timer.startup.record("hub")
|
||||||
|
|
||||||
import accelerate # pylint: disable=W0611,C0411
|
accelerate = None
|
||||||
|
try:
|
||||||
|
import accelerate # pylint: disable=W0611,C0411
|
||||||
|
except Exception as e:
|
||||||
|
report(f'accelerate=={accelerate.__version__ if "accelerate" in sys.modules else None}', e)
|
||||||
timer.startup.record("accelerate")
|
timer.startup.record("accelerate")
|
||||||
|
|
||||||
import pydantic # pylint: disable=W0611,C0411
|
pydantic = None
|
||||||
|
try:
|
||||||
|
import pydantic # pylint: disable=W0611,C0411
|
||||||
|
except Exception as e:
|
||||||
|
report(f'pydantic=={pydantic.__version__ if "pydantic" in sys.modules else None}', e)
|
||||||
timer.startup.record("pydantic")
|
timer.startup.record("pydantic")
|
||||||
|
|
||||||
try:
|
try:
|
||||||
|
|
@ -142,9 +161,13 @@ try:
|
||||||
fake_version_check.dep_version_check = lambda pkg, hint=None: None
|
fake_version_check.dep_version_check = lambda pkg, hint=None: None
|
||||||
except Exception:
|
except Exception:
|
||||||
pass
|
pass
|
||||||
import transformers # pylint: disable=W0611,C0411
|
transformers = None
|
||||||
from transformers import logging as transformers_logging # pylint: disable=W0611,C0411
|
try:
|
||||||
transformers_logging.set_verbosity_error()
|
import transformers # pylint: disable=W0611,C0411
|
||||||
|
from transformers import logging as transformers_logging # pylint: disable=W0611,C0411
|
||||||
|
transformers_logging.set_verbosity_error()
|
||||||
|
except Exception as e:
|
||||||
|
report(f'transformers=={transformers.__version__ if "transformers" in sys.modules else None}', e)
|
||||||
timer.startup.record("transformers")
|
timer.startup.record("transformers")
|
||||||
|
|
||||||
try:
|
try:
|
||||||
|
|
|
||||||
|
|
@ -29,7 +29,7 @@ requests==2.32.3
|
||||||
tqdm==4.67.3
|
tqdm==4.67.3
|
||||||
accelerate==1.13.0
|
accelerate==1.13.0
|
||||||
einops==0.8.1
|
einops==0.8.1
|
||||||
huggingface_hub==1.7.2
|
huggingface_hub==1.8.0
|
||||||
numpy==2.1.2
|
numpy==2.1.2
|
||||||
pandas==2.3.1
|
pandas==2.3.1
|
||||||
protobuf==6.33.5
|
protobuf==6.33.5
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue