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

First Order Motion Model ERROR at play_video #386

Open
marujunmac opened this issue May 22, 2023 · 3 comments
Open

First Order Motion Model ERROR at play_video #386

marujunmac opened this issue May 22, 2023 · 3 comments

Comments

@marujunmac
Copy link

Run First Order Motion Model at Google Colab.
When run "play_video('result/arbitrary/sample_src.png_by_sample_drv.mp4')",
export error below.


FileNotFoundError Traceback (most recent call last)
in <cell line: 1>()
----> 1 play_video('result/arbitrary/sample_src.png_by_sample_drv.mp4')

in play_video(filename, height, width)
4
5 def play_video(filename, height=512, width=512):
----> 6 mp4 = open(filename, 'rb').read()
7 data_url = "data:video/mp4;base64," + b64encode(mp4).decode()
8 return HTML(f"""

FileNotFoundError: [Errno 2] No such file or directory: 'result/arbitrary/sample_src.png_by_sample_drv.mp4'

Please teach me how to result this problem.

@TomonobuTsujikawa
Copy link
Contributor

Sorry for my late response.

When you click "RESTART RUNTIME" button, the current directory is changed to default (=/content ).
So, you need to change the directory again by %cd nnabla-examples/facial-motion-transfer/first-order-model.

But I find that updated scikit-image removed circle, and this causes another error.
So, here is the instruction to overcome these issues:

At first, run the following code (Installing scikit-image will take time on python3.10 environment) :

!pip install -U Pillow
!pip install -U scikit-image~=0.18.0

(RESTART RUNTIME might be needed)

Then, install nnabla and clone examples repository.
Finally, you need to change directory after clicking "RESTARTING RUNTIME".

We will update to be able to use latest scikit-image, but please try this instruction as of now.

Sorry for inconvenience.

@pdachiang
Copy link

thank you for your reply!
after i run the code you uploaded, the error has been fixed
it almost take 10 mins to realize the

!pip install -U scikit-image~=0.18.0

@TomonobuTsujikawa
Copy link
Contributor

Thank you for confirming!
Now we are updating our code to be able to use latest scikit-image by #389,
but this needs updated nnabla to be able to work this in Colab, so please wait a moment until v1.36.0 is released.

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