資源簡介
基于MATLAB編譯器,實現對圖像特征點的匹配,同時對匹配后的特征點進行篩選

代碼片段和文件信息
%?
%???Copyright?(C)?2016??Starsky?Wong?
%?
%???Note:?The?SIFT?algorithm?is?patented?in?the?United?States?and?cannot?be
%???used?in?commercial?products?without?a?license?from?the?University?of
%???British?Columbia.??For?more?information?refer?to?the?file?LICENSE
%???that?accompanied?this?distribution.
function?[feat_index]?=?addOriFeatures(ddata_indexfeat_indexddatahistnori_peak_ratio)
%?Function:?Add?good?orientation?for?keypoints
global?features;
global?init_sigma;
global?intvls;
omax?=?dominantOri(histn);
for?i?=?1:n
????if?(i==1)
????????????l?=?n;
????????????r?=?2;
????elseif?(i==n)
????????l?=?n-1;
????????r?=?1;
????else
????????l?=?i-1;
????????r?=?i+1;
????end
????if?(?hist(i)?>?hist(l)?&&?hist(i)?>?hist(r)?&&?hist(i)?>=?ori_peak_ratio*omax?)
????????bin?=?i?+?interp_hist_peak(hist(l)hist(i)hist(r));
????????if?(?bin?-1?<=?0?)
????????????bin?=?bin?+?n;
????????%?i?think?it‘s?theoretically?impossible
????????elseif?(?bin?-1?>?n?)
????????????bin?=?bin?-?n;
????????????disp(‘###################what?the?fuck?###################‘);
????????end
????????accu_intvl?=?ddata.intvl?+?ddata.x_hat(3);
????????features(feat_index).ddata_index?=?ddata_index;
????????%?first?octave?is?double?size
????????features(feat_index).x?=?(ddata.x?+?ddata.x_hat(1))*2^(ddata.octv-2);
????????features(feat_index).y?=?(ddata.y?+?ddata.x_hat(2))*2^(ddata.octv-2);
????????features(feat_index).scl?=?init_sigma?*?power(2ddata.octv-2?+?(accu_intvl-1)/intvls);????????
????????features(feat_index).ori?=?(bin-1)/n*2*pi?-?pi;
????????feat_index?=?feat_index?+?1;
????end
end
end
function?[omax]?=?dominantOri(histn)
????omax?=?hist(1);
????for?i?=?2:n
????????if(hist(i)?>?omax)
????????????omax?=?hist(i);
????????end
????end
end
function?[position]?=?interp_hist_peak(lcr)
????position?=?0.5*(l-r)/(l-2*c+r);
end
?屬性????????????大小?????日期????時間???名稱
-----------?---------??----------?-----??----
?????文件???????1909??2018-05-30?20:40??第二次\addOriFeatures.m
?????文件????????732??2018-05-30?20:39??第二次\calcGrad.m
?????文件????????480??2018-05-30?20:25??第二次\drawFeatures.m
?????文件???????1543??2018-05-30?20:26??第二次\drawMatched.m
?????文件????????598??2018-05-30?20:28??第二次\gaussian.m
?????文件???????8024??2018-05-30?20:22??第二次\getFeatures.m
?????文件????????551??2018-05-30?20:46??第二次\hist2Descr.m
?????文件???????1274??2018-05-30?20:43??第二次\interpHistEntry.m
?????文件???????2371??2018-05-30?20:31??第二次\interpLocation.m
?????文件????????796??2018-05-30?20:35??第二次\isEdgeLike.m
?????文件????????920??2018-05-30?20:24??第二次\match.m
?????文件???????3715??2018-06-20?19:29??第二次\match_ransac.m
?????文件????????860??2018-05-30?20:37??第二次\oriHist.m
?????文件????????333??2018-06-20?19:05??第二次\Run.m
?????文件??????26390??2018-05-30?20:32??第二次\s.jpg
?????文件????????747??2018-05-30?20:39??第二次\smoothOriHist.m
?????文件??????28680??2018-05-30?20:33??第二次\t1.jpg
?????文件??????25856??2018-05-30?20:33??第二次\t2.jpg
?????文件??????18839??2018-05-30?20:33??第二次\t3.jpg
?????文件??????53261??2018-06-20?18:35??第二次\wxy1.jpg
?????文件??????75677??2018-06-20?18:35??第二次\wxy2.jpg
?????文件??????38094??2018-05-30?18:40??第二次\{51ML[$8TLOZLS5ZH)]9W%J.png
?????文件????1004733??2018-05-30?20:57??第二次\第二次.docx
?????目錄??????????0??2018-07-21?12:39??第二次
-----------?---------??----------?-----??----
??????????????1296383????????????????????24
- 上一篇:DMA-TVP-FAVAR
- 下一篇:matlab空間桁架計算程序
評論
共有 條評論