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

Actual acceleration on Resnet #11

Open
albert-666 opened this issue Dec 9, 2021 · 2 comments
Open

Actual acceleration on Resnet #11

albert-666 opened this issue Dec 9, 2021 · 2 comments

Comments

@albert-666
Copy link

Thank you for your great work! I have a question about the latency. Could the method achieve actual acceleration on Resnet?

@changlin31
Copy link
Owner

Yes, it can achieve actual acceleration on ResNet. We plan to report detailed latency comparison on ResNet.

Please note that if practical acceleration on batch inference is wanted, the dynamic gate should be disabled, as dynamic mode only support sequential inference, i.e., one input at a time.

@lixinghe1999
Copy link

lixinghe1999 commented Mar 22, 2023

Edited.
Seems the default cfg is "mobilenet", which can't get acceleration on cuda.

Previous question:
@changlin31
Dear author,
I just tried model, however, I don't receive actual acceleration.

I test DSNet with "largest" and "smallest", 30 warm-up and 30 test. The input data is (1, 3, 224, 224)
The latency is almost the same.
My machine: GPU3060 + CUDA 11.2 + torch 1.12.
Note that I find one line in dyn_slim_ops/DSConv2d: self.channel_choice = -1, which can prohibit the inference of mode "smallest", so I temporarily comment it. Otherwise, the smallest model can only run once.
I have tested the intermediate feature shape, my "smallest" model actually gets a smaller feature shape, however, no actual acceleration is found.

Can you give me some hints? Am I misunderstanding?

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