Replies: 2 comments
-
"I encountered the same issue as you. I removed the line hidden_states = torch.cat([hidden_states, temb], dim=1) from unet_1d_blocks.py at line 516 in the class DownBlock1DNoSkip(nn.Module)." |
Beta Was this translation helpful? Give feedback.
0 replies
-
"I encountered the same issue as you. I removed the line hidden_states = torch.cat([hidden_states, temb], dim=1) from unet_1d_blocks.py at line 516 in the class DownBlock1DNoSkip(nn.Module)." |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
from diffusers import UNet1DModel,DDPMScheduler
noise_scheduler = DDPMScheduler(num_train_timesteps=1000, beta_schedule='squaredcos_cap_v2')
import torch
model=UNet1DModel( sample_size=1024,
in_channels=1,
out_channels=1,
layers_per_block=2,
block_out_channels=(32, 64,128),time_embedding_type="positional")
x=torch.randn(2,1,1024)
noise = torch.randn_like(x)
timesteps = torch.randint(0, 999, (x.shape[0],)).long()
noisy_x = noise_scheduler.add_noise(x, noise, timesteps)
pred = model(noisy_x, timesteps)
RuntimeError: Given groups=1, weight of size [32, 1, 1], expected input[2, 33, 1024] to have 1 channels, but got 33 channels instead
Beta Was this translation helpful? Give feedback.
All reactions