Temp
Last updated: 1/9/2025
Temp
I had a problem in one of my RSO's where I couldn't find the solution to a part of my project. I had to implement BART to predict the relatedness of two sequences of letters. I used PyTorch for this and to compute the similarity I used the cosine similarity for the outputs of the BART model and its loss function would be this distance between randomly chosen samples from my test and training datasets. I struggled to figure out how to do this and for a solid week nothing i wrote worked, my evaluation loss as always flat. i took a step back and asked the project lead for help and he told me that it is probably a simple error and that I should try and read every line of my code and find the error. He was right and I had a very silly error which was that I made the test dataset incorrectly and my original model had never seen any of the classes on the test dataset so of course it couldn't predict the similarity. It would be like asking an English speaker to distiugish dog and cat breeds but the names of the breeds were in Mandarin. I learned that I can make very silly mistakes and that when there is a complex problem there is probably a simple solution.