I am working with ChestXray data. I have found a model on Github.
Link GitHub - arnoweng/CheXNet: A pytorch reimplementation of CheXNet 2
I have downloaded the pre-trained model and loaded it in CUDA-based GPU. Now I want to test the code by using an image dataset. I believe the ChestXrayDataSet function is working properly. and I am using ChestXrayDataSet for test_dataset generation. Then I have used the DataLoader of PyTorch for creating the test_loader variable. Up to this everything works fine.
But when I’m using the enumerate in test_loader it is creating an error. I believe there is a problem with my lambda function in the test_dataset variable or the problem lies in the ChestXrayDataSet function. I have added the ChestXrayDataSet function and the other two images with errors!

tan21586×1687 255 KB