Find local maximum from jpg

2 visualizaciones (últimos 30 días)
Siegmund Nuyts
Siegmund Nuyts el 7 de En. de 2022
Respondida: Image Analyst el 8 de En. de 2022
I have a rgb JPG image and I'm wondering if I could extract local maximum from it.
The picture represents water on the beach so I'd like to quantify the edge of the water.
Could I for example draw transects over the JPG and extract the colour difference between water vs sand and then use 'findpeaks'?
Anyone suggestions on how to approach this?
  2 comentarios
yanqi liu
yanqi liu el 8 de En. de 2022
yes,sir,may i ask what is target?get the water edge and compare?
Siegmund Nuyts
Siegmund Nuyts el 8 de En. de 2022
Yes, ideally the individual peaks of the water edge in order to then compare (max, min, mean, ...)

Iniciar sesión para comentar.

Respuestas (2)

Walter Roberson
Walter Roberson el 7 de En. de 2022
JPG image ... quantify
Unless you are using the extremely-uncommon Lossless JPEG, those goals are fundamentally incompatible. Lossy JPEG blurs edges, and it is the edges that you need to quantify.
Basically, unless you can switch the source to a lossless image format such as PNG, then your project is probably not worth doing.
Note: if the camera supports RAW images, then those might be usable.

Image Analyst
Image Analyst el 8 de En. de 2022
I see about 3 different regions. I'm not sure what is sand or water or something else. If you use drawfreehand to manually trace the boundary, then you're done. You don't need any image analysis to find that boundary because you just drew it and you now have the coordinates.
There is a function to find regional maxima : imregionalmax(). But I don't think it will do what you're hoping for.
And like Walter said, you need to use a lossless format like PNG, not JPEG with the horrible compression artifacts as you can see in your image. If you do that, it might be possible to find the boundary without doing hand tracing.

Categorías

Más información sobre Convert Image Type en Help Center y File Exchange.

Productos


Versión

R2021b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by