Hi,
I have executed the following code but I am getting an error. Kindly provide the solution.
code:
encoding = img_to_encoding(image_path, model)
dist = np.linalg.norm(tf.subtract(encoding, database[identity]))
error:
ufunc ‘isfinite’ not supported for the input types, and the inputs could not be safely coerced to any supported types according to the casting rule ‘‘safe’’
If you have still having this problem, please provide the complete exception trace, so that we can see the context of the error. In general, it’s not our job to just solve your problems for you, but we can hope to give you some direction in how to debug a given situation. But that requires a bit more detail and context than you have provided here …
Hello Paul,
This query stands resolved.
Thanks for reaching out.
I have completed DLS and now on TensorFlow developer certificate course. Simultaneously, I was trying to do an image classification on Kaggle and I am getting a very low accuracy at present, so a lot of thinking is going around it. Also wonder why object detection and image segmentation tasks were not covered in TensorFlow developer certificate. DLS had a good foundational coverage for it.
Thanks and Regards
Aroonima
Also while I was solving the Kaggle problem i explored TF1, which has an endless list of image processing options. Not all of it but most of the image processing options are covered in Tf2 with the ImageDataGenerator. So I explored a lot of TF1. I suppose both versions complement each other.
I have not taken any of the TF specializations here on DLAI. I am actually surprised to hear that TF2 has less functionality in some areas than TF1. That doesn’t sound plausible to me. My suggestion would be that you look a little more carefully at the TF2 documentation or do a bit of googling. But TF1 is still out there is you are feeling masochistic.
Hey, I mind the simile you have used here.
But I took a close look and realize now that what I was exploring is all a part of TF2. Somehow the TF2 functionalities in the course were a bit limited.
I learnt about ImageDataGenerator in the course but while googling I came across image_dataset_from_directory, and did’nt realize that its also a part of TF2. I found this particular reading (image_dataset_from_directory) very interesting and useful.
Hi Paul,
How are you?
I have successfully completed the TensorFlow Developer Certificate and am looking forward to commence PDS course.
Thanks for your guidance
Regards
Aroonima
Hi, Aroonima.
Thanks for updating us on your progress. That all sounds great! I have not gotten around to taking anything other than DLS and GANs yet, but am hoping to have time for AI4M to learn about other applications of DL.
I’d be interested to hear your thoughts on PDS once you’ve had a look at that.
Keep in touch!
Regards,
Paul