The phash is all 0 when the image is more than 194 pixels wide and has a height of 64 pixels or less, e.g. a resolution of 195x64 pixels.
Steps to reproduce:
- Create a image with a resolution of 195x64 pixels
- Run TestRadish with this image
- The phash is all 0's
Problem:
- in ph_radon_projections,
projs.nb_pix_perline at index 134 is not changed, i.e. this value is 0
- in ph_feature_vector, there is a division with the 0 value from
projs.nb_pix_perline[134] (nb_pixels):
feat_v[k] = (line_sum_sqd / nb_pixels) -
(line_sum * line_sum) / (nb_pixels * nb_pixels);
The phash is all 0 when the image is more than 194 pixels wide and has a height of 64 pixels or less, e.g. a resolution of 195x64 pixels.
Steps to reproduce:
Problem:
projs.nb_pix_perlineat index 134 is not changed, i.e. this value is 0projs.nb_pix_perline[134](nb_pixels):