mirror of
https://github.com/AUTOMATIC1111/stable-diffusion-webui.git
synced 2025-01-17 11:50:18 +08:00
Update ddpm_edit.py
This commit is contained in:
parent
51cb20ec39
commit
61f321756f
@ -9,6 +9,7 @@ https://github.com/CompVis/taming-transformers
|
||||
# File modified by authors of InstructPix2Pix from original (https://github.com/CompVis/stable-diffusion).
|
||||
# See more details in LICENSE.
|
||||
|
||||
import sys
|
||||
import torch
|
||||
import torch.nn as nn
|
||||
import numpy as np
|
||||
@ -19,6 +20,8 @@ from contextlib import contextmanager
|
||||
from functools import partial
|
||||
from tqdm import tqdm
|
||||
from torchvision.utils import make_grid
|
||||
import pytorch_lightning.utilities.rank_zero
|
||||
sys.modules['pytorch_lightning.utilities.distributed'] = sys.modules['pytorch_lightning.utilities.rank_zero']
|
||||
from pytorch_lightning.utilities.rank_zero import rank_zero_only
|
||||
|
||||
from ldm.util import log_txt_as_img, exists, default, ismap, isimage, mean_flat, count_params, instantiate_from_config
|
||||
|
Loading…
Reference in New Issue
Block a user