tobyperrett / trx

Temporal-Relational CrossTransformers (CVPR 2021)
107 stars 23 forks source link

about query_per_class, query_per_test #8

Closed ycbilge closed 3 years ago

ycbilge commented 3 years ago

Thanks for the code again. When you are are changing the parameters for lets say 20-way 1-shot are you changing the parameters of _query_perclass, _query_pertest? Or should we just change --way and --shot parameters and leave the others as default? changing; parser.add_argument("--way", type=int, default=5, help="Way of each task.") -> 20 parser.add_argument("--shot", type=int, default=5, help="Shots per class.") -> 1 not changing; parser.add_argument("--query_per_class", type=int, default=5, help="Target samples (i.e. queries) per class used for training.") parser.add_argument("--query_per_class_test", type=int, default=1, help="Target samples (i.e. queries) per class used for testing.") Thanks for your help!

tobyperrett commented 3 years ago

Hi. You'd set --way 20 and --shot 1. The number of queries per class will affect training speed (by getting a better batch score using more queries), but uses more memory. You might have to select a value lower than 5 for it to fit on your GPU.