You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In the forward function of PatchMerging class, the msg_token and x was sent into self.reduction, which is a Conv2D layer with Conv2D(dim,2*dim,3,2,1) initialization.
However, the later one sent into it will cause an error:
Exception has occurred: IndexError
tuple index out of range
File "/home/yun/Coding/MSG-Transformer/models/msg_transformer.py", line 298, in forward
x = self.reduction(x).permute(0, 2, 3, 1)
File "/home/yun/Coding/MSG-Transformer/models/msg_transformer.py", line 384, in forward
x = self.downsample(x)
File "/home/yun/Coding/MSG-Transformer/models/msg_transformer.py", line 579, in forward_features
x = layer(x)
File "/home/yun/Coding/MSG-Transformer/models/msg_transformer.py", line 585, in forward
x = self.forward_features(x)
File "/home/yun/Coding/MSG-Transformer/main.py", line 168, in train_one_epoch
outputs = model(samples)
File "/home/yun/Coding/MSG-Transformer/main.py", line 134, in main
train_one_epoch(config, model, criterion, data_loader_train, optimizer, epoch, mixup_fn, lr_scheduler)
File "/home/yun/Coding/MSG-Transformer/main.py", line 356, in
main(config)
I tried change the order, letting x sent to Conv2D first and msg_token later but also cause this error.
Some of my environments here:
python 3.8.15
torchaudio 0.12.0 py38_cu113 pytorch
torchvision 0.13.0 py38_cu113 pytorch
pytorch 1.12.0 py3.8_cuda11.3_cudnn8.3.2_0 pytorch
timm 0.4.12 pypi_0 pypi
Would you please give some suggestions?
The text was updated successfully, but these errors were encountered:
In the forward function of PatchMerging class, the msg_token and x was sent into self.reduction, which is a Conv2D layer with Conv2D(dim,2*dim,3,2,1) initialization.
However, the later one sent into it will cause an error:
Exception has occurred: IndexError
tuple index out of range
File "/home/yun/Coding/MSG-Transformer/models/msg_transformer.py", line 298, in forward
x = self.reduction(x).permute(0, 2, 3, 1)
File "/home/yun/Coding/MSG-Transformer/models/msg_transformer.py", line 384, in forward
x = self.downsample(x)
File "/home/yun/Coding/MSG-Transformer/models/msg_transformer.py", line 579, in forward_features
x = layer(x)
File "/home/yun/Coding/MSG-Transformer/models/msg_transformer.py", line 585, in forward
x = self.forward_features(x)
File "/home/yun/Coding/MSG-Transformer/main.py", line 168, in train_one_epoch
outputs = model(samples)
File "/home/yun/Coding/MSG-Transformer/main.py", line 134, in main
train_one_epoch(config, model, criterion, data_loader_train, optimizer, epoch, mixup_fn, lr_scheduler)
File "/home/yun/Coding/MSG-Transformer/main.py", line 356, in
main(config)
I tried change the order, letting x sent to Conv2D first and msg_token later but also cause this error.
Some of my environments here:
python 3.8.15
torchaudio 0.12.0 py38_cu113 pytorch
torchvision 0.13.0 py38_cu113 pytorch
pytorch 1.12.0 py3.8_cuda11.3_cudnn8.3.2_0 pytorch
timm 0.4.12 pypi_0 pypi
Would you please give some suggestions?
The text was updated successfully, but these errors were encountered: