Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

what is the correct way to run demo? #27

Open
realcarlos opened this issue Sep 15, 2023 · 2 comments
Open

what is the correct way to run demo? #27

realcarlos opened this issue Sep 15, 2023 · 2 comments

Comments

@realcarlos
Copy link

realcarlos commented Sep 15, 2023

python preprocess.py --data_path data/woman-running.mp4 --inversion_prompt "a marble sculpture of a woman running, Venus de Milossets"

the "latents" folder is created , but the video file "inverted.mp4" is not changed .

then I run "python run_tokenflow_pnp.py"

Traceback (most recent call last):
File "/home/xxx/TokenFlow/run_tokenflow_pnp.py", line 300, in
run(config)
File "/home/xxx/TokenFlow/run_tokenflow_pnp.py", line 280, in run
editor.edit_video()
File "/home/xxx/TokenFlow/run_tokenflow_pnp.py", line 258, in edit_video
edited_frames = self.sample_loop(noisy_latents, torch.arange(self.config["n_frames"]))
File "/home/xxx/TokenFlow/run_tokenflow_pnp.py", line 267, in sample_loop
x = self.batched_denoise_step(x, t, indices)
File "/home/xxx/anaconda3/envs/tokenflow/lib/python3.9/site-packages/torch/amp/autocast_mode.py", line 14, in decorate_autocast
return func(*args, **kwargs)
File "/home/xxx/TokenFlow/run_tokenflow_pnp.py", line 227, in batched_denoise_step
self.denoise_step(x[pivotal_idx], t, indices[pivotal_idx])
File "/home/xxx/anaconda3/envs/tokenflow/lib/python3.9/site-packages/torch/utils/_contextlib.py", line 115, in decorate_context
return func(*args, **kwargs)
File "/home/xxx/TokenFlow/run_tokenflow_pnp.py", line 210, in denoise_step
noise_pred = self.unet(latent_model_input, t, encoder_hidden_states=text_embed_input)['sample']
File "/home/xxx/anaconda3/envs/tokenflow/lib/python3.9/site-packages/torch/nn/modules/module.py", line 1501, in _call_impl
return forward_call(*args, **kwargs)
File "/home/xxx/anaconda3/envs/tokenflow/lib/python3.9/site-packages/diffusers/models/unet_2d_condition.py", line 1018, in forward
sample = upsample_block(
File "/home/xxx/anaconda3/envs/tokenflow/lib/python3.9/site-packages/torch/nn/modules/module.py", line 1501, in _call_impl
return forward_call(*args, **kwargs)
File "/home/xxx/anaconda3/envs/tokenflow/lib/python3.9/site-packages/diffusers/models/unet_2d_blocks.py", line 2227, in forward
hidden_states = resnet(hidden_states, temb, scale=lora_scale)
File "/home/xxx/anaconda3/envs/tokenflow/lib/python3.9/site-packages/torch/nn/modules/module.py", line 1501, in _call_impl
return forward_call(*args, **kwargs)
TypeError: forward() got an unexpected keyword argument 'scale'

could you help?

@littlewhitesea
Copy link

littlewhitesea commented Sep 20, 2023

I also met with a similar problem. I solved it through installing an assigned version of diffusers as follows:

pip install diffusers==0.20.0

@nathanshipley
Copy link

Had the same problem: this fixed it! Thank you!

benjaminbojko added a commit to benjaminbojko/TokenFlow that referenced this issue Sep 23, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants