- 1、原创力文档(book118)网站文档一经付费(服务费),不意味着购买了该文档的版权,仅供个人/单位学习、研究之用,不得用于商业用途,未经授权,严禁复制、发行、汇编、翻译或者网络传播等,侵权必究。。
- 2、本站所有内容均由合作方或网友上传,本站不对文档的完整性、权威性及其观点立场正确性做任何保证或承诺!文档内容仅供研究参考,付费前请自行鉴别。如您付费,意味着您自己接受本站规则且自行承担风险,本站不退款、不进行额外附加服务;查看《如何避免下载的几个坑》。如果您已付费下载过本站文档,您可以点击 这里二次下载。
- 3、如文档侵犯商业秘密、侵犯著作权、侵犯人身权等,请点击“版权申诉”(推荐),也可以打举报电话:400-050-0827(电话支持时间:9:00-18:30)。
查看更多
Sobel Edge Detector 詳細的Sobel演算法流程,我就不再多談,請參考Sobel Edge Detector 。详细的Sobel演算法流程,,请参考 。 下圖的Gx與Gy是Sobel edge detector在X方向與Y方向的kernel,將與P5這個pixel做convolution。下图的Gx与Gy是Sobel edge detector在X方向与Y方向的kernel,将与P5这个pixel做convolution。
雖然是對P5運算,卻必須同時知道P1、P2、P3、P4、P6、P7、P8、P9的資訊,這在C不是問題,因為都在array內,只要改變一下array的index就可得到,但在Verilog卻做不到。虽然是对P5运算,却必须同时知道P1、P2、P3、P4、P6、P7、P8、P9的资讯,这在C不是问题,因为都在array内,只要改变一下array的index就可得到,但在Verilog却做不到。
系統架構圖 使用Verilog實現Sobel Edge Detector 使用Verilog实现Sobel Edge Detector
Sobel.v / Verilog Sobel.v / Verilog
1 /* 1 /* 2 (C) OOMusou 2008 2 (C) OOMusou 2008 3 3 4 Filename??? : Sobel.v 4 Filename : Sobel.v 5 Compiler??? : Quartus II 8.0 5 Compiler : Quartus II 8.0 6 Description : Demo how to implement Sobel Edge Detector on DE2-70 6 Description : Demo how to implement Sobel Edge Detector on DE2-70 7 Release???? : 09/27/2008 1.0 7 Release : 09/27/2008 1.0 8 */ 8 */ 9 9 10 module Sobel ( 10 module Sobel ( 11 11 ? input iCLK, input iCLK, 12 12 ? input iRST_N, input iRST_N, 13 13 ? input [ 7 : 0 ] iTHRESHOLD, input [ 7 : 0 ] iTHRESHOLD, 14 14 ? input iDVAL, input iDVAL, 15 15 ? input [ 9 : 0 ] iDATA, input [ 9 : 0 ] iDATA, 16 16 ? output output ? reg oDVAL, reg oDVAL, 17 17 ? output output ? reg [ 9 : 0 ] oDATA reg [ 9 : 0 ] oDATA 18 ); 18 ); 19 19 20 // mask x 20 // mask x 21 parameter X1 = 21 parameter X1 = ? 8 hff, X2 = 8 h00, X3 = 8 hff, X2 = 8 h00, X3 = ? 8 h01; 8 h01; 22 parameter X4 = 22 parameter X4 = ? 8 hfe, X5 = 8 h00, X6 = 8 hfe, X5 = 8 h00, X6 = ? 8 h02; 8 h02; 23 parameter X7 = 23 parameter X7 = ? 8 hff, X8 = 8 h00, X9 = 8 hff, X8 = 8 h00, X9 = ? 8 h01; 8 h01; 24 24 25 // mask y 25 // mask y 26 parameter Y1 = 26 parameter Y1 = ? 8 h01, Y2 = 8 h02, Y3 = 8 h01, Y2 = 8 h02, Y3 = ? 8 h01; 8 h01; 27 parameter Y4 = 27 parameter Y4 = ? 8 h00, Y5 = 8 h00, Y6 = 8 h00, Y5 = 8 h00, Y6 = ? 8 h00; 8 h00; 28 parameter Y7 = 28 parameter Y7 = ? 8 hff, Y8 = 8 hfe, Y9 = 8 hff, Y8 = 8 hfe, Y9 = ? 8 h
您可能关注的文档
最近下载
- 植树造林监理工程质量评估报告范文.docx
- 火力发电厂660MW机组新建工程主体工程精细化管理及控制措施.pptx VIP
- 猪肉加工介绍.ppt VIP
- 2023年贵州贵州高速公路集团有限公司招聘笔试真题.docx VIP
- 2024年江苏省苏州市中考语文模拟试卷.pdf VIP
- 调色师:达芬奇视频剪辑调色从入门到精通(下篇,共上中下3篇).pptx VIP
- 电池箱设计及安规要求.pdf VIP
- DG_TJ08-2062-2025 住宅工程套内质量验收标准.pdf VIP
- 安徽六校教育研究会2025届高三年级入学素质测试 物理试题(含答案详解).docx
- 在线网课《管理思想史》单元考核测试答案.docx VIP
文档评论(0)