PyTorch-Pretrained-ViT
PyTorch-Pretrained-ViT copied to clipboard
Vision Transformer (ViT) in PyTorch
Hi there, do you know how I can I use one of the two techniques above to do image classification on "Stanford Dogs Dataset"? I've already tried the "B_16_imagenet1k" model...
I want extract the transformer intermediate layer. I use follow code, but it does not work. nn.Sequential(*list(model.children()), how should i do?
Hi. Does anyone know how we can have access to attention maps?
Hi, When I try and run this with my own dataset with 4 classes, I get this error.  RuntimeError: view size is not...
Added support for 'H-14' and L'16' ViT models. Added support for downloading the models directly from Google's cloud storage. Corrected the Jax to Pytorch weights transformation. Previous methodology would lead...
Hi, Thanks for this implementation. I saw the parameters of nn.Linear() are set to no_gard() in models.py Line:139. ``` python @torch.no_grad() def init_weights(self): def _init(m): if isinstance(m, nn.Linear): nn.init.xavier_uniform_(m.weight) #...
I am using a pre-trained VIT model and trained on some different task but I got an error model.py file ``` class PositionalEmbedding1D(nn.Module): """Adds (optionally learned) positional embeddings to the...
i got ``` free(): invalid size Aborted (core dumped) ``` when i tried the example code for the classification . how can i solve it, please
First solved with "ViT(**image_size=image_size**)"
@lukemelas thanks for sharing code base , i had few queries 1.can we train crossvit for multilabel classification problem , if so what is the procedure 2. i have a...