mirror of
https://github.com/vladmandic/automatic
synced 2026-09-20 01:31:13 +02:00
@@ -306,7 +306,7 @@ def download_url_to_file(url: str, dst: str):
|
||||
continue
|
||||
break
|
||||
else:
|
||||
shared.log.error('Error downloading: url={url} no usable temporary filename found')
|
||||
shared.log.error(f'Error downloading: url={url} no usable temporary filename found')
|
||||
return
|
||||
try:
|
||||
with Progress(TextColumn('[cyan]{task.description}'), BarColumn(), TaskProgressColumn(), TimeRemainingColumn(), TimeElapsedColumn(), console=shared.console) as progress:
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
import typing
|
||||
import os
|
||||
import sys
|
||||
import time
|
||||
import torch
|
||||
import numpy as np
|
||||
|
||||
+2
-2
@@ -21,8 +21,8 @@ def encode(*args):
|
||||
class RestrictedUnpickler(pickle.Unpickler):
|
||||
extra_handler = None
|
||||
|
||||
def persistent_load(self, saved_id):
|
||||
assert saved_id[0] == 'storage'
|
||||
def persistent_load(self, pid):
|
||||
assert pid[0] == 'storage'
|
||||
try:
|
||||
return TypedStorage(_internal=True)
|
||||
except TypeError:
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
# pylint: disable=redefined-builtin,no-member,protected-access
|
||||
|
||||
from typing import Any, Dict, List, Tuple, Optional, Union
|
||||
from typing import Dict, List, Tuple, Optional, Union
|
||||
from dataclasses import dataclass
|
||||
from enum import Enum
|
||||
|
||||
@@ -463,7 +463,7 @@ class SDNQQuantizer(DiffusersQuantizer, HfQuantizer):
|
||||
*args, **kwargs, # pylint: disable=unused-argument
|
||||
):
|
||||
if self.pre_quantized:
|
||||
layer, tensor_name = get_module_from_name(model, param_name)
|
||||
layer, _tensor_name = get_module_from_name(model, param_name)
|
||||
if hasattr(layer, "sdnq_dequantizer"):
|
||||
return True
|
||||
elif param_name.endswith(".weight"):
|
||||
|
||||
@@ -8,4 +8,4 @@ current_dir = os.path.dirname(os.path.abspath(__file__))
|
||||
parent_dir = os.path.dirname(current_dir)
|
||||
if parent_dir not in sys.path:
|
||||
sys.path.insert(0, parent_dir)
|
||||
"""
|
||||
"""
|
||||
|
||||
@@ -1288,7 +1288,7 @@ class VideoAutoencoderKL(diffusers.AutoencoderKL):
|
||||
result_rows.append(torch.cat(result_row, dim=4))
|
||||
dec = torch.cat(result_rows, dim=3)
|
||||
return dec
|
||||
|
||||
|
||||
def forward(
|
||||
self, x: torch.FloatTensor, mode: Literal["encode", "decode", "all"] = "all", **kwargs
|
||||
):
|
||||
|
||||
Reference in New Issue
Block a user