@Henry_Chibueze @ptrblck
I think I can pinpoint the issue but I still can’t get it solved.
The problem is I don’t know how to get the predictions to look like the labels.
test_acc = 0.0
for _data in loaders['test']:
    with torch.no_grad():
        data, target = _data[:][:,:,:-1], _data[..., -1]
        data = data.permute(0, 2, 1)
        data, target = data.to(device), target.to(device)
        output = trained_model(data)
        # calculate accuracy
        _, pred = torch.max(output, dim=1) 

        correct = torch.sum(pred.eq(torch.max(target, 1)[1]))
        print(f'prediction: {pred}')
        print(f'label: {(torch.max(target, 1)[1])}')

        test_acc += torch.mean(correct.float())
print('Accuracy of the network on {} test frames: {}%'.format(len(tst_data3), round(test_acc.item()*100.0/len(loaders['test']), 2)))

If I print the prediction and the label, I get different values:
print(f'prediction: {pred}')

prediction: tensor([194,  86, 492, 492, 132, 132, 263, 216, 241,  17, 263, 216, 127, 399,
        492, 500, 420, 263, 390, 510, 216, 510, 132, 194, 263, 217, 263,  23,
        216, 395, 132, 297, 390, 194, 263, 492, 114, 216, 194, 503,  20, 217,
        297, 477, 476, 263, 263, 479, 466, 500, 132, 263, 361, 194,  92, 510,
        393, 216, 500,  53, 194, 510, 216, 216, 269, 216, 228, 194, 119, 415,
        477, 477, 114, 477, 476, 477, 503, 194, 170, 216, 263, 194, 221, 503,
        263, 466, 263, 114, 263, 492,  46, 449, 286, 286, 263, 132, 420, 406,
        492, 194, 263, 194, 263, 263, 194, 477, 114, 119, 477, 510, 241, 492,
        286, 263, 170, 216, 216, 194, 127, 263, 492, 477, 216, 114, 194, 360,
        479, 390], device='cuda:0')

print(f'label: {(torch.max(target, 1)[1])}')

label: tensor([3, 0, 0, 0, 1, 0, 6, 0, 2, 0, 5, 0, 1, 0, 4, 0, 0, 0, 0, 0, 0, 4, 0, 0,
        3, 0, 4, 2, 0, 6, 0, 0, 3, 0, 0, 3, 0, 0, 0, 1, 0, 0, 5, 0, 0, 6, 0, 0,
        0, 6, 0, 5, 0, 0, 6, 0, 1, 0, 4, 0, 0, 4, 0, 1, 0, 1, 0, 0, 0, 4, 0, 0,
        0, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 4, 0, 0, 6, 0, 0, 5, 0,
        0, 0, 1, 0, 3, 0, 3, 4, 0, 5, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 0, 0, 3, 0,
        0, 0, 1, 0, 1, 1, 0, 6], device='cuda:0')