microsoft / cvt Goto Github PK
View Code? Open in Web Editor NEWThis is an official implementation of CvT: Introducing Convolutions to Vision Transformers.
License: MIT License
This is an official implementation of CvT: Introducing Convolutions to Vision Transformers.
License: MIT License
Could you pls provide the config of CvT-W24 of finetune on 1k?
请问有适合关于Cifar10 或者Cifar100的模型 SPEC吗?
Is there a model SPEC for Cifar10 or Cifar100?
Thank you very much!
Hi,thanks for your work, could you release the 22k model?
Hi,
What's the accuracy of CvT-13 without pre-trained on CIFAR10? Mine is only 79.6. Would you like to told me yours? And what are the hyper-parameters for fine-tuning on CIFAR10 without pre-trained ? I can't find it in detail in the paper.
Thanks.
recommend change the following code int lib/models/cls_cvt.py:611
x = torch.squeeze(x) change to x = torch.squeeze(x, dim=1)
Otherwise, an error will occur when bachsize = 1
Hi,
I wonder how you computed the FLOPs. I used FlopCountAnalysis from fvcore.nn and it is larger than you reported.
Good job!
My question is that why to use different class tokens for each stage but only the final class token is used for classification?
Line 607 in 34d1af9
你好,请问我用imagenet1k进行训练时候,test精度好像完全没有变化,一直保持0.1左右,这是什么情况呢?
Hi,would you like to provide a classification model on ImageNet22k?
After installing torch 1.7.1, I got an ERROR:
ModuleNotFoundError: No module named 'torch.fx
What I find on stackoverflow is that torch.fx was added in PyTorch 1.8.0., so may be recommended version is wrong?
Hello, thanks for the great work, how to calculate the flops of the model. I have noticed that you report the flops of transformer based model, but I only found some tools of cnn models.
2021-07-20 16:52:11,694:[P:33903]:Rank[0/4] == get_model_complexity_info by ptflops ==
2021-07-20 16:52:11,796:[P:33903]:Rank[0/4] => FLOPs: 4.06 GMac, params: 20.0 M
2021-07-20 16:52:11,796:[P:33903]:Rank[0/4] == get_model_complexity_info by ptflops ==
while the paper shows the flops of CvT-13 is 4.5G
Hi, thanks for sharing the code, I am using a dataset that can be converted to images of size 750* 184, I was wondering what should I change in this code ?
thanks in advance
Hi, thanks for this repo!
Could you please share the configuration for ImageNet experiments? I suppose the config file here is not the one used for ImageNet, or at least doesn't reflect what is written in the paper (please correct me if I'm wrong).
Many thanks!
Is this a typo?
hi,
all models in modelzoo are not available.
Hi All,
Thanks for providing the code.
I come across the mismatch between the code and the theory you proposed for the transformer block. The paper says "Instead, we propose to replace the original position-wise linear projection for Multi-Head Self-Attention (MHSA)", but lines 198-200 in https://github.com/leoxiaobin/CvT/blob/main/lib/models/cls_cvt.py still projects q,k,v through linear layers. Have you missed an else statement there? why are you projecting q,k,v values twice?
Please correct me if I have misunderstood it.
Thanks,
Basavaraj
I want to konw why there isn't any to the function get_cls_model and compute_macs
I use the pretrained model CvT-13-224x224-IN-1k.pth, and test on Imagenet as the guide, but the result is terrible
"TEST: Loss 8.5690 Error@1 98.926% Error@5 97.844% Accuracy@1 1.074% Accuracy@5 2.156%"
Does anyone else have tested? Why is it?
2021-06-26 22:30:03,174:[P:3190309]:Rank[0/5] => switch to eval mode
2021-06-26 22:30:03,175:[P:3190312]:Rank[3/5] => Epoch[0]: train end, duration: 8942.97s
2021-06-26 22:30:03,176:[P:3190312]:Rank[3/5] => Epoch[0]: validate start
2021-06-26 22:30:03,176:[P:3190312]:Rank[3/5] => switch to eval mode
Traceback (most recent call last):
File "tools/train.py", line 211, in <module>
main()
File "tools/train.py", line 153, in main
args.distributed
File "/python3.6/site-packages/torch/autograd/grad_mode.py", line 26, in decorate_context
return func(*args, **kwargs)
File "/CvT/tools/../lib/core/function.py", line 133, in test
loss = criterion(outputs, y)
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.