Error using imread (line 440), PNG library failed: tEXt: chunk data is too large.
3 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
so far the code that i am using to read PNG files (max 50MB each) is running on 2011b matlab version and no issue, recently started running it on 2021a Matlab version,the above error is appearing.
imread Line 440 : [X, map] = call_format_specific_reader(); nothing much info to get from this line i guess
any leads on how to resovle this issue ir anyone come acrros the same issue
1 commentaire
Jayant Gangwar
le 23 Nov 2022
Hi Sivasankararao,
There is not much information that I can get from just the error message itself.
Can you attach the code file and Image files as well, so I can find out why the above error is appearing.
Réponses (1)
Rahul
le 5 Mai 2025
It appears as the PNG files you worked with in MATLAB R2011b contain metadata chunks such as tEXt which contain textual information. However, it appears that the updated library for reading images in MATLAB R2021a imposes stricter contraints on tEXt chunk.
There is no direct way to do this in MATLAb. Hence removing tEXt metadata from the images can be done using third party tools like: 'ImageMagick' and 'ExifTool'.
After removing the tEXt metadata, the images can be read through the 'imread' function.
Thanks.
0 commentaires
Voir également
Catégories
En savoir plus sur Standard File Formats 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!