• Join
  • Sign In with my.TI Login
Texas Instruments
  • Products
  • Applications
  • Tools & Software
  • Support & Community
  • Sample & Buy
  • About TI
Sample & Purchase Cart Sample & Purchase Cart
  • Search
  • Advanced
TI E2E™ Community
  • Support Forums
  • Blogs
  • Groups
  • Videos
  • 简体中文
  • More ...
TI Home » TI E2E Community » Support Forums » Digital Signal Processors (DSP) » DaVinci™ Video Processors » DM64x DaVinci Video Processor Forum » DM6437 Vlib2.1 Hough Transform
Share
DaVinci™ Video Processors
  • Forums
  • Announcements
Options
  • Subscribe via RSS

Forums

DM6437 Vlib2.1 Hough Transform

This question is answered
qbliu
Posted by qbliu
on Jun 08 2010 11:40 AM
Intellectual300 points

Hi ,

   When I use the function VLIB_houghLineFromList() in vlib for Hough Transform, I have a question: 

   First, I do not konwn what are  the parameters " ping pong pang peng" mean?

  Second, when I get the parameter "pOutHoughSpace" from  VLIB_houghLineFromList() , and I get the biggest pixels index in "pOutHoughSpace", for example 200, and I suppose the thetaRange is 180,  rhoMaxLength is 267.  How can i get the true Theta and Rho?  Theta = 200 / rhoMaxLength ,  Rho = 200 % rhoMaxLength ? What is the relation between the input parameter rhoMaxLength and the Rho/Theta?

  Thanks a lot.

dm6437 vlib hough
Report Abuse
  • Reply
You have posted to a forum that requires a moderator to approve posts before they are publicly available.
All Replies
  • Paul.Yin
    Posted by Paul.Yin
    on Jun 09 2010 14:36 PM
    Genius14385 points

    Hello, our expert is looking into this and will get back to you soon.

    PS: Please mark this post as answered via the Verify Answer button below if you think it answers your question.  Thanks!

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Senthil Kumar Yogamani
    Posted by Senthil Kumar Yogamani
    on Jun 09 2010 15:25 PM
    Verified Answer
    Verified by qbliu
    Intellectual1450 points

     

    Hello XianSheng,

    I am currently writing an application note and developing a simple project using VLIB Hough transform for line detection in an image.

    Please provide me your email id so that I can send you this project which would help you clarify all the details.

    Your second question is the reason why I am doing the above as there are multiple ways to implement the Hough transform.

    ping, pong, pang and peng are temporary buffers used to optimization.

    Please refer to the documentation and the VLIB_testhough file for more details.

    Regards

    Senthil

    Regards,

    Senthil

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • qbliu
    Posted by qbliu
    on Jun 09 2010 23:53 PM
    Verified Answer
    Verified by qbliu
    Intellectual300 points

    Hello Senthil ,

       Thanks very much for your reply.

       My email id is liuqingben511@163.com or dsp.support@zlgmcu.com

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Junsu Jang
    Posted by Junsu Jang
    on Aug 18 2010 19:55 PM
    Suggested Answer
    Prodigy35 points

    Hello XianSheng and Senthil,

    I also want to know how to retrieve actual theta and rho value.

    Would you share the document for me?

    My email is junsu.jang@lge.com

    Thank you very much.

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Senthil Kumar Yogamani
    Posted by Senthil Kumar Yogamani
    on Aug 19 2010 06:20 AM
    Intellectual1450 points

     

    Hello Junsu,

    I emailed you an example project.

    Please let me know if you need anything more.

    Regards

    Senthil

     

    Regards,

    Senthil

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Junsu Jang
    Posted by Junsu Jang
    on Aug 19 2010 21:31 PM
    Prodigy35 points

    I got the example project. Thank you very much.

    I am trying to exchange simulink hough transform block to VLIB_houghLineFromList block.

    Is rhoMaxLength always the same as thetaRange?

    The calculatedOutHoughSpace seems wrong, when rhoMaxLength changes to bigger number.

    In my  understanding of hough transform, when input image is 320*240, then rho range is -400 ~ +400 (sqrt(320^2 + 240^2)).

    It seems the rho range is different in the draw_line.c. 

    Would you explain what following codes means?

    diameter = SQRTof2_Q8*max(W,H);

      normLength = 267 << 16;
      normLength /= diameter;  
      normLength /= 2;  

    I tested simulink hough block with 1deg resolution of theta and 1pixel resolution of rho, but I don't know how to set the resolutions and the range for theta and rho in VLIB_houghLineFromList block. Can I get 'trigs.m' that generates sin, cos table?

    Best regards,

    -Junsu

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Senthil Kumar Yogamani
    Posted by Senthil Kumar Yogamani
    on Aug 20 2010 06:22 AM
    Intellectual1450 points

     

    Junsu,

    Two years back, I worked with Mathworks to replace the Simulink Hough transform block to VLIB_hough transform block for their Lane Departure Demo.

    I remember doing a few hacks to get it working as the line represenations were different in Matlab and VLIB and also had to compensate for the rho and theta transformations.

    Answering your questions below:

      // Diameter of Hough Space which is max abs value of r  = sqrt(W^2 + H^2 ) [this  is approximated by the value below]
      diameter = SQRTof2_Q8 * max(W, H);

      // Scale factor for r to rho conversion
      normLength = 267<< 16;
      normLength /= diameter;  
      normLength /= 2;         

    The actual 'r' is quantized to a new variable with rhoMaxLength as the number of bins for quantization.

    For example, 'r' can take any floating point value from -r_max to + r_max. This range is mapped to discrete bins 0,1,2 ... rhoMaxLength which will act as the indexes in the Hough Space. From the bin index, you need to extract the actual 'r' by doing the inverse of quantization which is what is illustrated in the sample project I sent you.

    So in your example, 400 is actually r_max and not rhomaxLength and it can be different from thetaRange. This range of values -400 to 400 is mapped to discrete indices 0,1,2....267.

    VLIB_testHough.c provided in VLIB contains the VLIB_InitializeTrigLUTs function which generates the sin and cos tables.

    Please feel free to ask for more clarification if required.

    Regards

    Senthil

    Regards,

    Senthil

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Junsu Jang
    Posted by Junsu Jang
    on Aug 31 2010 06:08 AM
    Prodigy35 points

    Senthil,

    I tested VLIB_hough transform with different rhoMaxLength.

    Is there any maximum value for rhoMaxLength?

    When I set high value for rhoMaxLength, HoughOut was not correct.

    ex) for 360*120 images, rhoMaxLength = 380 works well

    but rhoMaxLength = 600 does not work properly. I observed overlapping voting count appear in HoughOut.

    If the range -r_max ~ +r_max is divided into rhoMaxLength bins equally, different rhoMaxLength generates only scaled pattern of HoughOut.

    I will send you a picture showing overlapping pattern of HoughOut since I cannnot attach picture here.

    Thanks,

    Junsu

     

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Ayyala
    Posted by Ayyala
    on Sep 29 2010 03:31 AM
    Prodigy15 points

    Hello Senthil,

    Can you also send me the example project for Hough transform using VLIB.

    My email Id is a_pradyumna<at>yahoo<dot>com 

     Also I suggest upload the example project so that others can easily find it.

     

    Thank you,

    Regards.

    Ayyala

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Senthil Kumar Yogamani
    Posted by Senthil Kumar Yogamani
    on Sep 29 2010 04:43 AM
    Suggested Answer
    Intellectual1450 points

     

    Ayyala,

    I emailed you the example project.

    We are planning to clean it up and release it with VLIB.

    Regards

    Senthil

    Regards,

    Senthil

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • shan54218
    Posted by shan54218
    on Oct 01 2010 07:40 AM
    Intellectual645 points

    Hello senthil,

               I unfortunately erase the flash program while doing some programs , But i burn the flash program in the cd (dm6437_demo.hex) i have also burn it in the flash using flash utility but it was not working properly....

    So please give some solution to get my board to the Default state......

    regards

    shan

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • YunFei He
    Posted by YunFei He
    on Oct 04 2010 08:59 AM
    Prodigy140 points

    Hello,I need the vlib ,where can I download the vlib? do you have it?   email:hyunfei19862008@163.com     sorry,my English is very poor!!!!!

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Senthil Kumar Yogamani
    Posted by Senthil Kumar Yogamani
    on Oct 04 2010 11:00 AM
    Intellectual1450 points

     

    Hello YunFei,

    Please use the following link and fill the form for approval of VLIB - www.ti.com/vlibrequest

    Regards,

    Senthil

     

    Regards,

    Senthil

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Senthil Kumar Yogamani
    Posted by Senthil Kumar Yogamani
    on Oct 04 2010 11:05 AM
    Suggested Answer
    Intellectual1450 points

     

    Shan,

    I dont know how to fix this issue.

    I will try to find out and let you know.

    Regards,

    Senthil

    Regards,

    Senthil

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Hugo Lin
    Posted by Hugo Lin
    on Mar 24 2011 06:30 AM
    Prodigy10 points

    Hello XianSheng and Senthil and Junsu,

    I also want to know how to retrieve actual theta and rho value.

    Would you share the document for me?

    My email is iopp50@gmail.com

    Thank you very much.

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
12
TI E2E™ Community
  • Support Forums
  • Blogs
  • Videos
  • Groups
  • Site Support & Feedback
  • Settings
TI E2E™ Community Groups
  • TI University Program
  • Make the Switch
  • Microcontroller Projects
  • Motor Drive & Control
Other Communities
  • Deyisupport
  • Designsomething.org
  • beagleboard.org
  • TI on Element 14
  • TI on TechXchangeSM
Other Technical & Support Resources
  • WEBENCH® Design Center
  • Product Information Centers
  • Technical Documents
  • TI Design Network
  • TI Technical Articles
  • TI Training

All content and materials on this site are provided "as is". TI and its respective suppliers and providers of content make no representations about the suitability of these materials for any purpose and disclaim all warranties and conditions with regard to these materials, including but not limited to all implied warranties and conditions of merchantability, fitness for a particular purpose, title and non-infringement of any third party intellectual property right. TI and its respective suppliers and providers of content make no representations about the suitability of these materials for any purpose and disclaim all warranties and conditions with respect to these materials. No license, either express or implied, by estoppel or otherwise, is granted by TI. Use of the information on this site may require a license from a third party, or a license from TI.

Content on this site may contain or be subject to specific guidelines or limitations on use. All postings and use of the content on this site are subject to the Terms of Use of the site; third parties using this content agree to abide by any limitations or guidelines and to comply with the Terms of Use of this site. TI, its suppliers and providers of content reserve the right to make corrections, deletions, modifications, enhancements, improvements and other changes to the content and materials, its products, programs and services at any time or to move or discontinue any content, products, programs, or services without notice.

Follow Us Texas Instruments on Facebook Texas Instruments on Twitter Texas Instruments on LinkedIn Texas Instruments on Google+
TI Worldwide | Contact Us | my.TI Login | Site Map | Corporate Citizenship | mobile m.ti.com (Mobile Version)

TI is a global semiconductor design and manufacturing company. Innovate with 100,000+ analog ICs and
embedded processors, along with software, tools and the industry’s largest sales/support staff.

© Copyright 1995-2013 Texas Instruments Incorporated. All rights reserved.
Trademarks | Privacy Policy | Terms of Use