日韩性视频-久久久蜜桃-www中文字幕-在线中文字幕av-亚洲欧美一区二区三区四区-撸久久-香蕉视频一区-久久无码精品丰满人妻-国产高潮av-激情福利社-日韩av网址大全-国产精品久久999-日本五十路在线-性欧美在线-久久99精品波多结衣一区-男女午夜免费视频-黑人极品ⅴideos精品欧美棵-人人妻人人澡人人爽精品欧美一区-日韩一区在线看-欧美a级在线免费观看

歡迎訪問 生活随笔!

生活随笔

當前位置: 首頁 > 编程资源 > 编程问答 >内容正文

编程问答

基于三点说构成的夹角提取特征点

發布時間:2023/12/20 编程问答 44 豆豆
生活随笔 收集整理的這篇文章主要介紹了 基于三点说构成的夹角提取特征点 小編覺得挺不錯的,現在分享給大家,幫大家做個參考.

clear all;

clc;

aa=xlsread('E:\chilun05188.xlsx');

N=length(aa);

ang=0:(0.4*2*205*pi*0.000001/60):(0.4*2*205*pi*0.000001/60)*(N-1);

ang=ang';

aa=aa+116.6479;

%基于三點說構成的夾角提取特征點

cc=1;

s=20;? %間隔s個點進行一次計算

t=0.12;? ? ?%用于調整特征點的位置

for k=1:s:N-2*s

? ? A=[ang(k) aa(k)];

? ? B=[ang(k+s) aa(k+s)];

? ? C=[ang(k+2*s) aa(k+2*s)];

? ? a1=B(1)-A(1)+j*(B(2)-A(2));

? ? a2=C(1)-B(1)+j*(C(2)-B(2));

? ? alpha(1,cc)=(angle(a2)-angle(a1))*180/pi;

? ? cc=cc+1;

?end

alpha=alpha';

tw=find(abs(alpha)>t);? ?%滿足要求的齒頂齒根數據點在原數組中的索引位置

l_tw=length(tw);

tw_diff=diff(tw);

w_tw=find(tw_diff>20);

w1_feature_points1=tw(w_tw)*s;

w2_feature_points1=tw(w_tw+1)*s;

tw_one=tw(1)*s

tw_last=tw(l_tw)*s

w1_feature_points=[w1_feature_points1' tw_last];? ? %齒形分離特征點在原數組中的索引位置

w2_feature_points=[tw_one w2_feature_points1'];? ? ?%齒形分離特征點在原數組中的索引位置

l_w1_feature_points=length(w1_feature_points');

w_feature_points=sort([w1_feature_points w2_feature_points]);

t1=1;

t2=1;

for k1=1:2:l_w1_feature_points

? ? w_one_1(1,t1)=w_feature_points(2*k1-1);

? ? w_one_2(1,t2)=w_feature_points(2*k1);

? ? t1=t1+1;

? ? t2=t2+1;

end

w_one=sort([w_one_1 w_one_2]);? ? ? ?%齒頂特征點在原數組中的索引位置

t3=1;

t4=1;

for k2=2:2:l_w1_feature_points

? ? w_other_1(1,t3)=w_feature_points(2*k2-1);

? ? w_other_2(1,t4)=w_feature_points(2*k2);

? ? t3=t3+1;

? ? t4=t4+1;

end

w_other=sort([w_other_1 w_other_2]);? ? ?%齒根特征點在原數組中的索引位置

?

figure(1)

polar(ang,aa,'k')

hold on

polar(ang(w_one),aa(w_one),'.r')

hold on

polar(ang(w_other),aa(w_other),'.g')

figure(2)

plot(ang,aa)

hold on

plot(ang(w_one),aa(w_one),'.r','MarkerSize',20)

hold on

plot(ang(w_other),aa(w_other),'.g','MarkerSize',20)

總結

以上是生活随笔為你收集整理的基于三点说构成的夹角提取特征点的全部內容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網站內容還不錯,歡迎將生活随笔推薦給好友。