dimensions problem with processImagesMNIST
1 vue (au cours des 30 derniers jours)
Afficher commentaires plus anciens
Hi,
Im trying to load MNIST dataset based on the instructions here:
But for some reason when i call :
XTrain = processImagesMNIST(filenameImagesTrain);
i get the following error:
Error using reshape
Number of elements must not change. Use [] as one of the size inputs to automatically calculate the appropriate size for that dimension.
Error in processImagesMNIST (line 31)
X = reshape(X,numCols,numRows,numImages);
Error in main (line 49)
XTrain = processImagesMNIST(filenameImagesTrain);
and when i call :
XTest = processImagesMNIST(filenameImagesTest);
i get the following error:
Error using reshape
Size vector elements should be nonnegative.
Error in processImagesMNIST (line 31)
X = reshape(X,numCols,numRows,numImages);
Does anyone know what im doing wrong?
Thanks
1 commentaire
Anshika Chaurasia
le 2 Nov 2021
Hi,
I ran the code in MATLAB R2021a and R2021b and didn't get any error.
Which MATLAB version you are using?
Can you share the script which is throwing the error? This will help to reproduce the error at our end.
Réponses (0)
Voir également
Catégories
En savoir plus sur Logical dans Help Center et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!