You can not select more than 25 topics Topics must start with a chinese character,a letter or number, can include dashes ('-') and can be up to 35 characters long.

template.py 2.5 kB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192
  1. templatesv1 = [
  2. 'a photo of {}'
  3. ]
  4. templatesv2 = [
  5. 'a photo of {}, a type of dog.',
  6. 'a photo of {}, a type of food.',
  7. 'a photot of {}, a type of animal.',
  8. 'a photo of {}.',
  9. ]
  10. templatesv3 = [
  11. 'a bad photo of a {}.',
  12. 'a photo of many {}.',
  13. 'a sculpture of a {}.',
  14. 'a photo of the hard to see {}.',
  15. 'a low resolution photo of the {}.',
  16. 'a rendering of a {}.',
  17. 'graffiti of a {}.',
  18. 'a bad photo of the {}.',
  19. 'a cropped photo of the {}.',
  20. 'a tattoo of a {}.',
  21. 'the embroidered {}.',
  22. 'a photo of a hard to see {}.',
  23. 'a bright photo of a {}.',
  24. 'a photo of a clean {}.',
  25. 'a photo of a dirty {}.',
  26. 'a dark photo of the {}.',
  27. 'a drawing of a {}.',
  28. 'a photo of my {}.',
  29. 'the plastic {}.',
  30. 'a photo of the cool {}.',
  31. 'a close-up photo of a {}.',
  32. 'a black and white photo of the {}.',
  33. 'a painting of the {}.',
  34. 'a painting of a {}.',
  35. 'a pixelated photo of the {}.',
  36. 'a sculpture of the {}.',
  37. 'a bright photo of the {}.',
  38. 'a cropped photo of a {}.',
  39. 'a plastic {}.',
  40. 'a photo of the dirty {}.',
  41. 'a jpeg corrupted photo of a {}.',
  42. 'a blurry photo of the {}.',
  43. 'a photo of the {}.',
  44. 'a good photo of the {}.',
  45. 'a rendering of the {}.',
  46. 'a {} in a video game.',
  47. 'a photo of one {}.',
  48. 'a doodle of a {}.',
  49. 'a close-up photo of the {}.',
  50. 'a photo of a {}.',
  51. 'the origami {}.',
  52. 'the {} in a video game.',
  53. 'a sketch of a {}.',
  54. 'a doodle of the {}.',
  55. 'a origami {}.',
  56. 'a low resolution photo of a {}.',
  57. 'the toy {}.',
  58. 'a rendition of the {}.',
  59. 'a photo of the clean {}.',
  60. 'a photo of a large {}.',
  61. 'a rendition of a {}.',
  62. 'a photo of a nice {}.',
  63. 'a photo of a weird {}.',
  64. 'a blurry photo of a {}.',
  65. 'a cartoon {}.',
  66. 'art of a {}.',
  67. 'a sketch of the {}.',
  68. 'a embroidered {}.',
  69. 'a pixelated photo of a {}.',
  70. 'itap of the {}.',
  71. 'a jpeg corrupted photo of the {}.',
  72. 'a good photo of a {}.',
  73. 'a plushie {}.',
  74. 'a photo of the nice {}.',
  75. 'a photo of the small {}.',
  76. 'a photo of the weird {}.',
  77. 'the cartoon {}.',
  78. 'art of the {}.',
  79. 'a drawing of the {}.',
  80. 'a photo of the large {}.',
  81. 'a black and white photo of a {}.',
  82. 'the plushie {}.',
  83. 'a dark photo of a {}.',
  84. 'itap of a {}.',
  85. 'graffiti of the {}.',
  86. 'a toy {}.',
  87. 'itap of my {}.',
  88. 'a photo of a cool {}.',
  89. 'a photo of a small {}.',
  90. 'a tattoo of the {}.',
  91. ]

冻结ViT-B/32版本的CLIP模型中的全部图像层,用Adan优化器训练模型,训练100个epoch,每隔5个epoch对模型进行保存;完成CLIP模型训练后,运行test_clip.py用测试集中的数据和自定义的提示词对保存的模型进行测试,选取测试精度最好的模型和对应的提示词,运行predict.py文件,选择“min_loss.pth”模型,提交官方系统测试,top1的精度是0.6788。

Contributors (1)