how can i find the distance from the peak of one wave to another wave in a image?
1 visualización (últimos 30 días)
Mostrar comentarios más antiguos
basha Shaik
el 19 de Feb. de 2020
Comentada: darova
el 26 de Feb. de 2020
i need to find the distance of the wave. i refer to some questions & answers from that i get to know can solve canny's edge detection method.
but i don't know how to process it. can anyone help me...?
4 comentarios
Respuesta aceptada
darova
el 19 de Feb. de 2020
I suggest next algorithm
- imcrop region of interest (since it's always at the same position
- imbinarize image
- maybe clear a bit with bwareaopen
- find pixels you are interested in
- use findpeaks
17 comentarios
darova
el 24 de Feb. de 2020
In case of other error try this:
function main
for i = 0:1
try
STR = sprintf('%05d.jpg',i);
write_length(STR);
pause(1)
catch ME
if ~exist(STR,'file')
disp(['File ' STR ' Does not exist'])
else
disp(ME.identifier)
disp(['File ' STR ' was not processed'])
end
end
end
end
Más respuestas (1)
basha Shaik
el 25 de Feb. de 2020
7 comentarios
darova
el 25 de Feb. de 2020
I changed angle of breakup for 2.jpg
if atan2d(dy(end),dx(end)) > 130 % angle of breakup
Result
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/273652/image.jpeg)
I think 11.jpg is defective. I don't see here a wave. Can you see?
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/273653/image.jpeg)
8.jpg is problem. I don't how to measure a wave length. Sorry
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/273654/image.jpeg)
Ver también
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!