-
大小: 580KB文件類型: .zip金幣: 2下載: 0 次發布日期: 2021-06-07
- 語言: 其他
- 標簽: Graph-Based??Image??Segmentation??
資源簡介
Efficient Graph-Based Image Segmentation論文的實現代碼,以及給了一個測試樣例,在Linux下運行通過

代碼片段和文件信息
/*
Copyright?(C)?2006?Pedro?Felzenszwalb
This?program?is?free?software;?you?can?redistribute?it?and/or?modify
it?under?the?terms?of?the?GNU?General?Public?License?as?published?by
the?Free?Software?Foundation;?either?version?2?of?the?License?or
(at?your?option)?any?later?version.
This?program?is?distributed?in?the?hope?that?it?will?be?useful
but?WITHOUT?ANY?WARRANTY;?without?even?the?implied?warranty?of
MERCHANTABILITY?or?FITNESS?FOR?A?PARTICULAR?PURPOSE.??See?the
GNU?General?Public?License?for?more?details.
You?should?have?received?a?copy?of?the?GNU?General?Public?License
along?with?this?program;?if?not?write?to?the?Free?Software
Foundation?Inc.?59?Temple?Place?Suite?330?Boston?MA??02111-1307?USA
*/
#include?
#include?
#include?
#include?
#include?
#include?“segment-image.h“
int?main(int?argc?char?**argv)?{
??if?(argc?!=?6)?{
????fprintf(stderr?“usage:?%s?sigma?k?min?input(ppm)?output(ppm)\n“?argv[0]);
????return?1;
??}
??
??float?sigma?=?atof(argv[1]);
??float?k?=?atof(argv[2]);
??int?min_size?=?atoi(argv[3]);
??printf(“loading?input?image.\n“);
??image?*input?=?loadPPM(argv[4]);
??printf(“processing\n“);
??int?num_ccs;?
??image?*seg?=?segment_image(input?sigma?k?min_size?&num_ccs);?
??savePPM(seg?argv[5]);
??printf(“got?%d?components\n“?num_ccs);
??printf(“done!?uff...thats?hard?work.\n“);
??return?0;
}
?屬性????????????大小?????日期????時間???名稱
-----------?---------??----------?-----??----
?????目錄???????????0??2014-09-03?15:03??FelzenSegment\
?????文件????????2009??2013-05-31?23:33??FelzenSegment\convolve.h
?????文件???????18326??2013-05-31?23:33??FelzenSegment\COPYING
?????文件????????1857??2013-05-31?23:33??FelzenSegment\disjoint-set.h
?????文件????????3073??2013-05-31?23:33??FelzenSegment\filter.h
?????文件????????2395??2013-05-31?23:33??FelzenSegment\image.h
?????文件????????5103??2013-05-31?23:33??FelzenSegment\imconv.h
?????文件????????1714??2013-05-31?23:33??FelzenSegment\imutil.h
?????文件?????????361??2013-05-31?23:33??FelzenSegment\Makefile
?????文件????????1796??2013-05-31?23:33??FelzenSegment\misc.h
?????文件????????5464??2013-05-31?23:33??FelzenSegment\pnmfile.h
?????文件?????????807??2013-05-31?23:33??FelzenSegment\README
?????文件???????25874??2014-09-03?15:02??FelzenSegment\regions.jpg
?????文件??????478515??2014-09-02?10:44??FelzenSegment\regions.PPM
?????文件????????2191??2013-05-31?23:33??FelzenSegment\segment-graph.h
?????文件????????4298??2013-05-31?23:33??FelzenSegment\segment-image.h
?????文件????????1460??2013-05-31?23:33??FelzenSegment\segment.cpp
?????文件??????106805??2007-01-09?19:42??FelzenSegment\test.jpg
?????文件??????478515??2014-08-27?17:45??FelzenSegment\test.PPM
?????文件???????17920??2014-09-03?15:02??FelzenSegment\Thumbs.db
- 上一篇:一個DPCM的源代碼
- 下一篇:AdaBoost講解
評論
共有 條評論