lets say inp is [a , b, c ,d] then i guess i have to shift it it to the right, since its a transformer. then i will do this
[‘sos’,a , b, c ,d , ‘eos’] this is trg inp, since it (seq len, bz ) dim, i do trg_inp[:1, :] which is [a,b,c,d, ‘eos’], as at the first position the transformer should see only ‘sos’ (from trg) and first word of source to output ‘a’.
ps - a,b,c,d are words of the sentence