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

Performance issue #18

Closed
donnydonny123 opened this issue Mar 6, 2019 · 4 comments
Closed

Performance issue #18

donnydonny123 opened this issue Mar 6, 2019 · 4 comments

Comments

@donnydonny123
Copy link

Hi @sniklaus ,

In the original PWC-net paper, PWC-net's processing time is about 28ms.
image

But when I measured the time passed in run.py's estimate function and moduleNetwork, they cost about 330ms for estimate function and 173ms for moduleNetwork, which is too large to ignore.

I want to know that is there a reason that causes this issue. Thanks!

@sniklaus
Copy link
Owner

sniklaus commented Mar 6, 2019

What is the input resolution for the table that you quoted? And which graphics card are you using?

@donnydonny123
Copy link
Author

Hi,
In the original paper's conclusion, 1024*436 images is used for benchmark.
The command I am using is the same as provided in https://github.com/sniklaus/pytorch-pwc#usage ,
Which is python run.py --model default --first ./images/first.png --second ./images/second.png --out ./out.flo
GPU is GTX 1080 ti.
Thank you for your reply.

@sniklaus
Copy link
Owner

sniklaus commented Mar 6, 2019

Interesting find, thank you for bringing this up! Calling moduleNetwork in a for loop using the provided images clocks in at around 130 ms per estimate on my 1080 Ti, still much too slow. Note to everyone reading this and who might not be aware of the asynchronous computation nature of GPU computing, making sure to use torch.cuda.synchronize() to get the correct timing. Have you tried benchmarking the official release? If so, what is the timing you get? Thanks!

@sniklaus
Copy link
Owner

sniklaus commented Mar 13, 2019

Closing the issue due to inactivity, I would still love to hear more about this though!

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

2 participants