Closed gowtham1997 closed 2 years ago
Thanks for your interest.
stage_tiny_something_p7
is my custom model so they are not in timm model. They are in the models of the repo.
I have a plan to deploy my pretrained weights. So if you want to use, please wait or train the model in ImageNet-1k by using the repo.
Thanks for your prompt reply.
They are in the models of the repo.
How should I go about training these custom models on some other dataset?
python train.py ..\medical_mnist\ --model stage_tiny_lin_p4 --amp
^ for eg, I tried this on medical mnist to test and it gives me the following traceback.
Training with a single process on 1 GPUs.
Traceback (most recent call last):
File "project\Fair-Comparison-between-Efficient-Attentions\train.py", line 1428, in <module>
main()
File "project\Fair-Comparison-between-Efficient-Attentions\train.py", line 854, in main
model = create_model(
File "D:\miniconda\envs\efficient\lib\site-packages\timm\models\factory.py", line 71, in create_model
model = create_fn(pretrained=pretrained, pretrained_cfg=pretrained_cfg, **kwargs)
File "project\Fair-Comparison-between-Efficient-Attentions\models\linformer.py", line 78, in stage_tiny_lin_p4
model = StageTransformer(partial(Block, attn_layer=LinAttention), **cfg)
File "project\Fair-Comparison-between-Efficient-Attentions\models\base.py", line 309, in __init__
layer = BasicLayer(
File "project\Fair-Comparison-between-Efficient-Attentions\models\base.py", line 189, in __init__
[
File "project\Fair-Comparison-between-Efficient-Attentions\models\base.py", line 190, in <listcomp>
block(
File "project\Fair-Comparison-between-Efficient-Attentions\models\base.py", line 93, in __init__
self.attn = attn_layer(
TypeError: __init__() got an unexpected keyword argument 'pretrained_cfg'
Can you also let me know the timm version you used to test this?
I used the instructions in the repo to create the conda env, but I feel this could still be an issue with the library version of timm ?
I guess so too. I check the version, and it is timm=0.5.4
.
If you have a problem despite using that version, please notice. Thank you!
Seems to work now Thanks
Hello,
Thanks for this fantastic work.
I was looking at your wandb to use similar models on another dataset but seems that the model_names like
stage_tiny_lin_p7
,stage_tiny_swin_p7
, etc arent timm models(?) ( I getTypeError: __init__() got an unexpected keyword argument 'pretrained_cfg'
when I use these names)Can you let us know the list of model names to use to test all these different architectures on another dataset?