WeichenXu123 commented on pull request #34187: URL: https://github.com/apache/spark/pull/34187#issuecomment-937668269
According to the code here: https://github.com/apache/spark/blob/2e9b698d3100f18595dadbf35abb06502c3d6123/mllib/src/main/scala/org/apache/spark/ml/image/ImageSchema.scala#L134 `ImageIO.read(new ByteArrayInputStream(bytes))` the `bytes` is an array in memory, so will the real IO exception happen ? Seems like real IO exception is impossible. If so, we can catch all kinds of exception raised by `ImageIO.read` and regards all of them as invalid image cases. @srowen @HyukjinKwon What do you think ? -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
