fix bugs
This commit is contained in:
@@ -6,6 +6,8 @@ ComfyUI DynamiCrafter
|
||||
|
||||
base workflow
|
||||
|
||||
<img src="assets/wf_basic.png" raw=true>
|
||||
<img src="wf_basic.png" raw=true>
|
||||
|
||||
https://github.com/chaojie/ComfyUI-DynamiCrafter/blob/main/workflow.json
|
||||
https://github.com/chaojie/ComfyUI-DynamiCrafter/blob/main/workflow.json
|
||||
|
||||
<img src="video.gif" raw=true>
|
||||
@@ -6,8 +6,8 @@ from einops import rearrange
|
||||
import torch.nn.functional as F
|
||||
import pytorch_lightning as pl
|
||||
from ..modules.networks.ae_modules import Encoder, Decoder
|
||||
from .distributions import DiagonalGaussianDistribution
|
||||
from ...utils import instantiate_from_config
|
||||
from ..distributions import DiagonalGaussianDistribution
|
||||
from ...utils.utils import instantiate_from_config
|
||||
|
||||
|
||||
class AutoencoderKL(pl.LightningModule):
|
||||
|
||||
@@ -9,12 +9,12 @@ try:
|
||||
XFORMERS_IS_AVAILBLE = True
|
||||
except:
|
||||
XFORMERS_IS_AVAILBLE = False
|
||||
from lvdm.common import (
|
||||
from ..common import (
|
||||
checkpoint,
|
||||
exists,
|
||||
default,
|
||||
)
|
||||
from lvdm.basics import zero_module
|
||||
from ..basics import zero_module
|
||||
|
||||
|
||||
class RelativePosition(nn.Module):
|
||||
|
||||
@@ -4,8 +4,8 @@ import kornia
|
||||
import open_clip
|
||||
from torch.utils.checkpoint import checkpoint
|
||||
from transformers import T5Tokenizer, T5EncoderModel, CLIPTokenizer, CLIPTextModel
|
||||
from lvdm.common import autocast
|
||||
from utils.utils import count_params
|
||||
from ...common import autocast
|
||||
from ....utils.utils import count_params
|
||||
|
||||
|
||||
class AbstractEncoder(nn.Module):
|
||||
|
||||
@@ -4,8 +4,8 @@ import torch
|
||||
import numpy as np
|
||||
import torch.nn as nn
|
||||
from einops import rearrange
|
||||
from utils.utils import instantiate_from_config
|
||||
from lvdm.modules.attention import LinearAttention
|
||||
from ....utils.utils import instantiate_from_config
|
||||
from ..attention import LinearAttention
|
||||
|
||||
def nonlinearity(x):
|
||||
# swish
|
||||
|
||||
@@ -4,16 +4,16 @@ import torch
|
||||
import torch.nn as nn
|
||||
from einops import rearrange
|
||||
import torch.nn.functional as F
|
||||
from lvdm.models.utils_diffusion import timestep_embedding
|
||||
from lvdm.common import checkpoint
|
||||
from lvdm.basics import (
|
||||
from ...models.utils_diffusion import timestep_embedding
|
||||
from ...common import checkpoint
|
||||
from ...basics import (
|
||||
zero_module,
|
||||
conv_nd,
|
||||
linear,
|
||||
avg_pool_nd,
|
||||
normalization
|
||||
)
|
||||
from lvdm.modules.attention import SpatialTransformer, TemporalTransformer
|
||||
from ..attention import SpatialTransformer, TemporalTransformer
|
||||
|
||||
|
||||
class TimestepBlock(nn.Module):
|
||||
|
||||
@@ -48,7 +48,7 @@ class DynamiCrafterSimple:
|
||||
image = 255.0 * image[0].cpu().numpy()
|
||||
#image = Image.fromarray(np.clip(image, 0, 255).astype(np.uint8))
|
||||
|
||||
imgs= image2video.get_image(image, prompt, steps, cfg_scale, eta, motion, seed)
|
||||
imgs= model.get_image(image, prompt, steps, cfg_scale, eta, motion, seed)
|
||||
return imgs
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user