

{"id":120186,"date":"2024-03-16T18:00:32","date_gmt":"2024-03-16T12:30:32","guid":{"rendered":"https:\/\/data-flair.training\/blogs\/?p=120186"},"modified":"2024-03-16T18:13:44","modified_gmt":"2024-03-16T12:43:44","slug":"canny-edge-detection-using-opencv","status":"publish","type":"post","link":"https:\/\/data-flair.training\/blogs\/canny-edge-detection-using-opencv\/","title":{"rendered":"Canny Edge Detection using OpenCV"},"content":{"rendered":"<p>Step into the realm where images reveal their hidden secrets. Welcome to the world of &#8216;OpenCV Canny Edge Detection.&#8217;<\/p>\n<p>In this journey, we&#8217;ll delve into the wizardry of algorithms that transform seemingly ordinary pictures into landscapes of edges and contours. Just as a skilled artist highlights every brushstroke, Canny Edge Detection illuminates the intricate details of objects, opening a gateway to a new dimension of image interpretation.<\/p>\n<p>Prepare to be captivated as we unravel the magic behind this technique and harness the power of OpenCV to see the unseen.<\/p>\n<h2>Let&#8217;s first define edge detection, shall we?<\/h2>\n<p>A fundamental method of image processing called edge detection looks for boundaries inside a picture. In essence, it&#8217;s the process of highlighting abrupt changes in intensity or color between neighboring pixels. These changes often correspond to significant transitions in the underlying objects or structures present in the image.<\/p>\n<p>Edge detection algorithms work by analyzing the gradient of intensity or color in an image. They identify regions where the gradient is the steepest, indicating potential edges. The output of an edge detection process is typically a binary image where edge pixels are marked, providing a clear visual representation of object boundaries.<\/p>\n<p>One of the most popular and effective edge detection techniques is the Canny edge detection algorithm. It&#8217;s celebrated for its ability to accurately locate edges while minimizing false positives and negatives. Through careful processing involving blurring, gradient calculation, non-maximum suppression, and thresholding, the Canny algorithm transforms raw pixel data into a map of pronounced edges.<\/p>\n<h3>Let\u2019s Know Hysteresis Thresholding<\/h3>\n<p>At this stage, it is determined which edges are actually edges and which ones are not. We require the threshold values minVal and maxVal for this. Any edges with gradients of intensity more than maxVal are certain to be edges, and any below minVal are certain to be non-edges, so they should be disregarded. Based on their connectedness, those who fall between these two thresholds are categorized as edges or non-edges. They are regarded as being a part of edges if they are linked to &#8220;sure-edge&#8221; pixels. If not, they are likewise thrown away.<\/p>\n<p><strong>Look at the picture below:<\/strong><\/p>\n<p><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2023\/11\/Hysteresis-Thresholding-below.webp\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter wp-image-125965 size-full\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2023\/11\/Hysteresis-Thresholding-below.webp\" alt=\"Hysteresis Thresholding below\" width=\"450\" height=\"263\" \/><\/a><\/p>\n<p>The edge A is a &#8220;sure-edge&#8221; because it is above the maximum value. The whole curve is obtained even though edge C is below maxVal since it connects to edge A, which is likewise regarded as a legitimate edge. Although edge B is in the same region as edge C and is above minVal, it is not related to any other &#8220;sure-edges&#8221; and is therefore disregarded. Therefore, it is crucial that we choose minVal and maxVal appropriately in order to obtain the desired outcome.<\/p>\n<p>On the grounds that edges are long lines, this stage also eliminates noise from little pixels.<\/p>\n<h4>Suppression :<\/h4>\n<p>After determining the gradient&#8217;s size and direction, the entire image is scanned to weed out any extraneous pixels that might not be the edge. For this, it is determined whether each pixel is a local maximum in its neighborhood in the gradient&#8217;s direction. See the illustration below:<\/p>\n<p><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2023\/11\/Hysteresis-Thresholding-suppression.webp\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter wp-image-125968 size-full\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2023\/11\/Hysteresis-Thresholding-suppression.webp\" alt=\"Hysteresis Thresholding suppression\" width=\"450\" height=\"198\" \/><\/a><\/p>\n<p>In a vertical sense, Point A is at the edge. The edge&#8217;s gradient direction is typical. Points B and C are on a gradient. So, points A, B, and C are examined to determine whether they constitute a local maximum. If so, it is taken into account for the following step; if not, it is suppressed (set to zero).<\/p>\n<p>A binary image with &#8220;thin edges&#8221; is the end outcome, to put it briefly.<\/p>\n<h3>Canny Edge Detection in OpenCV: Revealing Hidden Structures<\/h3>\n<p>Unveil the magic of edge detection with the precision of OpenCV&#8217;s Canny algorithm. This section brings you into the heart of image interpretation, where edges are more than meets the eye. Dive into the workings of Canny edge detection, explore its key steps, and master its implementation through cv2.Canny().<\/p>\n<h4>Working of Canny Edge Detection:<\/h4>\n<p><strong>1. Smoothing:<\/strong><\/p>\n<ul>\n<li>The process begins by applying a Gaussian blur to the input image. This blurring operation reduces noise and removes small variations in pixel intensity that could be erroneously detected as edges.<\/li>\n<li>The Gaussian blur is achieved by convolving the image with a Gaussian kernel, which assigns more weight to the central pixels and gradually decreases the weight towards the edges of the kernel.<\/li>\n<\/ul>\n<p><strong>2. Gradient Calculation:<\/strong><\/p>\n<ul>\n<li>The gradient magnitude and direction at each pixel of the blurred image are calculated using the Sobel operator.<\/li>\n<li>The gradient magnitude reveals the rate of intensity change at a given pixel, indicating potential edge locations. Higher gradients correspond to rapid intensity changes, which are characteristic of edges.<\/li>\n<li>The gradient direction provides insight into the orientation of the edges. It&#8217;s calculated separately for the x and y directions and is often converted to an angle in degrees.<\/li>\n<\/ul>\n<p><strong>3. Non-Maximum Suppression:<\/strong><\/p>\n<ul>\n<li>This step enhances edge thinning by suppressing non-maximum pixels in the gradient direction.<\/li>\n<li>In order to compare the gradient magnitude of the current pixel with its neighbors, the algorithm scans along the gradient direction. The only pixel that is kept is the one with the greatest gradient magnitude in its immediate neighborhood.<\/li>\n<li>The result is a thinned set of edge pixels that form continuous lines along the most pronounced intensity changes.<\/li>\n<\/ul>\n<p><strong>4. Hysteresis Thresholding:<\/strong><\/p>\n<ul>\n<li>Edge pixels are classified into three categories: strong edges, weak edges, and non-edges.<\/li>\n<li>This stage aims to link weak edges to strong edges, forming coherent edge contours.<\/li>\n<li>Pixels with gradient magnitudes above the higher threshold are considered strong edges. Pixels below the lower threshold are disregarded as non-edges.<\/li>\n<li>Pixels with gradient magnitudes between the two thresholds are marked as weak edges. If a weak edge pixel is adjacent to a strong edge pixel, it&#8217;s promoted to a strong edge pixel, contributing to continuous edge contours.<\/li>\n<\/ul>\n<p>Mastering the intricacies of Canny edge detection empowers you to decipher the intricate structures within images. By grasping each step, you can leverage the algorithm&#8217;s power to highlight significant transitions, opening the door to advanced image analysis and computer vision tasks.<\/p>\n<h4>cv2.Canny():<\/h4>\n<p><strong>Syntax:<\/strong><\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">edges = cv2.Canny(image, threshold1, threshold2, apertureSize, L2gradient)<\/pre>\n<p><strong>Parameters:<\/strong><\/p>\n<ul>\n<li><strong>Image:<\/strong> The source image.<\/li>\n<li><strong>Threshold1, threshold2:<\/strong> Lower and upper thresholds for edge linking.<\/li>\n<li><strong>apertureSize:<\/strong> Size of the Sobel kernel (optional).<\/li>\n<li><strong>L2gradient:<\/strong> Flag for using L2 gradient norm (optional).<\/li>\n<\/ul>\n<p><strong>Code with Explanation:<\/strong><\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">import cv2\r\n\r\n# Load the source image\r\nsrc_image = cv2.imread(r\"C:\\Users\\satchit\\OneDrive\\Desktop\\OpenCV Data Flair\\opencv cannyedge detection\\wildlife-tiger.jpg\", cv2.IMREAD_GRAYSCALE)\r\n\r\n# Apply Gaussian blur to the source image\r\nblurred_image = cv2.GaussianBlur(src_image, (5, 5), 0)\r\n\r\n# Apply Canny edge detection using cv2.Canny()\r\nedges = cv2.Canny(blurred_image, threshold1=100, threshold2=200)\r\n\r\n# Display the original image\r\ncv2.imshow('Original Image', src_image)\r\ncv2.waitKey(0)\r\n\r\n# Display the blurred image\r\ncv2.imshow('Blurred Image', blurred_image)\r\ncv2.waitKey(0)\r\n\r\n# Display the edge-detected image\r\ncv2.imshow('Edge-Detected Image', edges)\r\ncv2.waitKey(0)\r\n\r\ncv2.destroyAllWindows()<\/pre>\n<p><strong>Original Image:<\/strong><\/p>\n<p><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2023\/11\/Canny-Edge-Detection-original.webp\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter wp-image-125969 size-full\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2023\/11\/Canny-Edge-Detection-original.webp\" alt=\"Canny Edge Detection original\" width=\"796\" height=\"713\" \/><\/a><\/p>\n<p><strong>Blurred Image:<\/strong><\/p>\n<p><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2023\/11\/Canny-Edge-Detection-blurred.webp\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter wp-image-125970 size-full\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2023\/11\/Canny-Edge-Detection-blurred.webp\" alt=\"Canny Edge Detection blurred\" width=\"795\" height=\"717\" \/><\/a><\/p>\n<p><strong>Canny Image:<\/strong><\/p>\n<p><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2023\/11\/Canny-Edge-Detection-.webp\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter wp-image-125971 size-full\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2023\/11\/Canny-Edge-Detection-.webp\" alt=\"Canny Edge Detection\" width=\"797\" height=\"712\" \/><\/a><\/p>\n<p><strong>Explanation:<\/strong><\/p>\n<p>1. Load the grayscale source image using cv2.imread() with cv2.IMREAD_GRAYSCALE.<\/p>\n<p>2. Apply Canny edge detection using cv2.Canny(). Adjust `threshold1` and `threshold2` to control edge detection sensitivity.<\/p>\n<p>3. Display both the original grayscale image and the edge-detected image using cv2.imshow().<\/p>\n<p>Mastering Canny edge detection opens a window to image features hidden in plain sight. By understanding its intricacies and implementing it through OpenCV, you&#8217;re equipped to unravel the structural secrets embedded within images, making your visual interpretation more insightful than ever before.<\/p>\n<h3>Canny Image with ApertureSize and L2gradient: Enhancing Edge Detection Precision<\/h3>\n<p>In the realm of image analysis, precision is paramount. Dive into the nuanced world of Canny edge detection in OpenCV, where we explore how adjusting the ApertureSize and utilizing the L2gradient parameter can refine edge detection results. In this section, we&#8217;ll unravel the syntax, parameters, and code implementation of Canny edge detection, allowing you to master the art of accentuating image boundaries with finesse.<\/p>\n<h4>cv2.Canny() with ApertureSize and L2gradient:<\/h4>\n<p><strong>Syntax:<\/strong><\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">edges = cv2.Canny(image, threshold1, threshold2, apertureSize, L2gradient)<\/pre>\n<p><strong>Parameters:<\/strong><\/p>\n<ul>\n<li><strong>Image:<\/strong> The source image.<\/li>\n<li><strong>threshold1, threshold2:<\/strong> Lower and upper thresholds for edge linking.<\/li>\n<li><strong>apertureSize:<\/strong> Size of the Sobel kernel. The default is 3.<\/li>\n<li><strong>L2gradient:<\/strong> Flag for using L2 gradient norm. The default is False.<\/li>\n<\/ul>\n<p><strong>Code with Explanation:<\/strong><\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">import cv2\r\n\r\n# Load the source image\r\nsrc_image = cv2.imread(r\"C:\\Users\\satchit\\OneDrive\\Desktop\\OpenCV Data Flair\\opencv cannyedge detection\\wildlife-tiger.jpg\", cv2.IMREAD_GRAYSCALE)\r\n# Apply Canny edge detection with ApertureSize and L2gradient using cv2.Canny()\r\nedges = cv2.Canny(src_image, threshold1=100, threshold2=200, apertureSize=5, L2gradient=True)\r\n# Display the original and edge-detected images\r\ncv2.imshow('Original Image', src_image)\r\ncv2.imshow('Edge-Detected Image', edges)\r\ncv2.waitKey(0)\r\ncv2.destroyAllWindows()<\/pre>\n<p><strong>Original Image:<\/strong><\/p>\n<p><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2023\/11\/ApertureSize-and-L2gradient-original.webp\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter wp-image-125974 size-full\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2023\/11\/ApertureSize-and-L2gradient-original.webp\" alt=\"ApertureSize and L2gradient original\" width=\"796\" height=\"713\" \/><\/a><\/p>\n<p><strong>Image with ApertureSize and L2gradient:<\/strong><\/p>\n<p><a href=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2023\/11\/ApertureSize-and-L2gradient-.webp\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter wp-image-125975 size-full\" src=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2023\/11\/ApertureSize-and-L2gradient-.webp\" alt=\"ApertureSize and L2gradient\" width=\"802\" height=\"720\" \/><\/a><\/p>\n<p><strong>Explanation:<\/strong><\/p>\n<p>1. Load the grayscale source image using cv2.imread() with cv2.IMREAD_GRAYSCALE.<\/p>\n<p>2. Apply Canny edge detection using cv2.Canny(). Fine-tune edge detection by adjusting threshold1 and threshold2.<\/p>\n<p>3. Incorporate the apertureSize parameter to define the Sobel kernel size. A larger apertureSize may capture longer edges effectively.<\/p>\n<p>4. Utilize the L2gradient parameter to compute the gradient magnitude using the L2 norm, enhancing edge detection accuracy.<\/p>\n<p>5. Display both the original grayscale image and the edge-detected image using cv2.imshow().<\/p>\n<p>Through harnessing ApertureSize and L2gradient, you hold the reins to mold Canny edge detection to your needs. These parameters allow you to achieve greater precision, ensuring your edge detection results align harmoniously with the intricacies of your images.<\/p>\n<h3>Summary<\/h3>\n<p>In the realm of image analysis, we&#8217;ve embarked on a voyage through Canny edge detection, uncovering the subtleties that define object boundaries. With a glimpse into the world of ApertureSize and the potency of L2gradient, you&#8217;ve unlocked the keys to precision.<\/p>\n<p>A minor adjustment to ApertureSize yielded remarkable results, allowing you to sculpt edges with finesse. Meanwhile, embracing L2gradient magnified the accuracy of edge detection, delivering pixel-perfect outcomes.<\/p>\n<p>As we observed these facets in action through code, the transformative impact on edge detection became evident. Armed with this newfound mastery, you&#8217;re poised to unravel the complex narratives embedded in images. Each parameter tweak, each code snippet, draws you closer to a realm where pixels are narratives waiting to be read.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Step into the realm where images reveal their hidden secrets. Welcome to the world of &#8216;OpenCV Canny Edge Detection.&#8217; In this journey, we&#8217;ll delve into the wizardry of algorithms that transform seemingly ordinary pictures&#46;&#46;&#46;<\/p>\n","protected":false},"author":86671,"featured_media":132174,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[27755],"tags":[30117,30116,31028,9267,30115,29991],"class_list":["post-120186","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-opencv-tutorials","tag-canny-edge-detection","tag-canny-edge-detection-using-opencv","tag-learn-opencv","tag-opencv","tag-opencv-canny-edge-detection","tag-opencv-tutorials"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.8 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Canny Edge Detection using OpenCV - DataFlair<\/title>\n<meta name=\"description\" content=\"OpenCV Canny Edge Detection illuminates the intricate details of objects, opening a gateway to a new dimension of image interpretation.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/data-flair.training\/blogs\/canny-edge-detection-using-opencv\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Canny Edge Detection using OpenCV - DataFlair\" \/>\n<meta property=\"og:description\" content=\"OpenCV Canny Edge Detection illuminates the intricate details of objects, opening a gateway to a new dimension of image interpretation.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/data-flair.training\/blogs\/canny-edge-detection-using-opencv\/\" \/>\n<meta property=\"og:site_name\" content=\"DataFlair\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/DataFlairWS\/\" \/>\n<meta property=\"article:published_time\" content=\"2024-03-16T12:30:32+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2024-03-16T12:43:44+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2023\/11\/opencv-cannyedge-detection.webp\" \/>\n\t<meta property=\"og:image:width\" content=\"1200\" \/>\n\t<meta property=\"og:image:height\" content=\"628\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/webp\" \/>\n<meta name=\"author\" content=\"TechVidvan Team\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@DataFlairWS\" \/>\n<meta name=\"twitter:site\" content=\"@DataFlairWS\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"TechVidvan Team\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"9 minutes\" \/>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Canny Edge Detection using OpenCV - DataFlair","description":"OpenCV Canny Edge Detection illuminates the intricate details of objects, opening a gateway to a new dimension of image interpretation.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/data-flair.training\/blogs\/canny-edge-detection-using-opencv\/","og_locale":"en_US","og_type":"article","og_title":"Canny Edge Detection using OpenCV - DataFlair","og_description":"OpenCV Canny Edge Detection illuminates the intricate details of objects, opening a gateway to a new dimension of image interpretation.","og_url":"https:\/\/data-flair.training\/blogs\/canny-edge-detection-using-opencv\/","og_site_name":"DataFlair","article_publisher":"https:\/\/www.facebook.com\/DataFlairWS\/","article_published_time":"2024-03-16T12:30:32+00:00","article_modified_time":"2024-03-16T12:43:44+00:00","og_image":[{"width":1200,"height":628,"url":"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2023\/11\/opencv-cannyedge-detection.webp","type":"image\/webp"}],"author":"TechVidvan Team","twitter_card":"summary_large_image","twitter_creator":"@DataFlairWS","twitter_site":"@DataFlairWS","twitter_misc":{"Written by":"TechVidvan Team","Est. reading time":"9 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/data-flair.training\/blogs\/canny-edge-detection-using-opencv\/#article","isPartOf":{"@id":"https:\/\/data-flair.training\/blogs\/canny-edge-detection-using-opencv\/"},"author":{"name":"TechVidvan Team","@id":"https:\/\/data-flair.training\/blogs\/#\/schema\/person\/0e594f928e31fc96628ac40f6ae74f49"},"headline":"Canny Edge Detection using OpenCV","datePublished":"2024-03-16T12:30:32+00:00","dateModified":"2024-03-16T12:43:44+00:00","mainEntityOfPage":{"@id":"https:\/\/data-flair.training\/blogs\/canny-edge-detection-using-opencv\/"},"wordCount":1498,"commentCount":0,"publisher":{"@id":"https:\/\/data-flair.training\/blogs\/#organization"},"image":{"@id":"https:\/\/data-flair.training\/blogs\/canny-edge-detection-using-opencv\/#primaryimage"},"thumbnailUrl":"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2023\/11\/opencv-cannyedge-detection.webp","keywords":["canny edge detection","canny edge detection using opencv","learn opencv","opencv","opencv canny edge detection","opencv tutorials"],"articleSection":["OpenCV Tutorials"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/data-flair.training\/blogs\/canny-edge-detection-using-opencv\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/data-flair.training\/blogs\/canny-edge-detection-using-opencv\/","url":"https:\/\/data-flair.training\/blogs\/canny-edge-detection-using-opencv\/","name":"Canny Edge Detection using OpenCV - DataFlair","isPartOf":{"@id":"https:\/\/data-flair.training\/blogs\/#website"},"primaryImageOfPage":{"@id":"https:\/\/data-flair.training\/blogs\/canny-edge-detection-using-opencv\/#primaryimage"},"image":{"@id":"https:\/\/data-flair.training\/blogs\/canny-edge-detection-using-opencv\/#primaryimage"},"thumbnailUrl":"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2023\/11\/opencv-cannyedge-detection.webp","datePublished":"2024-03-16T12:30:32+00:00","dateModified":"2024-03-16T12:43:44+00:00","description":"OpenCV Canny Edge Detection illuminates the intricate details of objects, opening a gateway to a new dimension of image interpretation.","breadcrumb":{"@id":"https:\/\/data-flair.training\/blogs\/canny-edge-detection-using-opencv\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/data-flair.training\/blogs\/canny-edge-detection-using-opencv\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/data-flair.training\/blogs\/canny-edge-detection-using-opencv\/#primaryimage","url":"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2023\/11\/opencv-cannyedge-detection.webp","contentUrl":"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2023\/11\/opencv-cannyedge-detection.webp","width":1200,"height":628,"caption":"opencv canny edge detection"},{"@type":"BreadcrumbList","@id":"https:\/\/data-flair.training\/blogs\/canny-edge-detection-using-opencv\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Blog Home","item":"https:\/\/data-flair.training\/blogs\/"},{"@type":"ListItem","position":2,"name":"OpenCV Tutorials","item":"https:\/\/data-flair.training\/blogs\/category\/opencv-tutorials\/"},{"@type":"ListItem","position":3,"name":"Canny Edge Detection using OpenCV"}]},{"@type":"WebSite","@id":"https:\/\/data-flair.training\/blogs\/#website","url":"https:\/\/data-flair.training\/blogs\/","name":"DataFlair","description":"Learn Today. Lead Tomorrow.","publisher":{"@id":"https:\/\/data-flair.training\/blogs\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/data-flair.training\/blogs\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/data-flair.training\/blogs\/#organization","name":"DataFlair","url":"https:\/\/data-flair.training\/blogs\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/data-flair.training\/blogs\/#\/schema\/logo\/image\/","url":"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2016\/07\/Data-Flair.png","contentUrl":"https:\/\/data-flair.training\/blogs\/wp-content\/uploads\/sites\/2\/2016\/07\/Data-Flair.png","width":106,"height":48,"caption":"DataFlair"},"image":{"@id":"https:\/\/data-flair.training\/blogs\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/www.facebook.com\/DataFlairWS\/","https:\/\/x.com\/DataFlairWS","https:\/\/www.linkedin.com\/company\/dataflair-web-services-pvt-ltd\/","https:\/\/www.youtube.com\/user\/DataFlairWS"]},{"@type":"Person","@id":"https:\/\/data-flair.training\/blogs\/#\/schema\/person\/0e594f928e31fc96628ac40f6ae74f49","name":"TechVidvan Team","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/c89190da3d4010c71ba476b618ab10fdc2335c82cdfa0ad5002d98d0f2473444?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/c89190da3d4010c71ba476b618ab10fdc2335c82cdfa0ad5002d98d0f2473444?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/c89190da3d4010c71ba476b618ab10fdc2335c82cdfa0ad5002d98d0f2473444?s=96&d=mm&r=g","caption":"TechVidvan Team"},"description":"TechVidvan Team provides high-quality content &amp; courses on AI, ML, Data Science, Data Engineering, Data Analytics, programming, Python, DSA, Android, Flutter, full stack web dev, MERN, and many latest technology.","url":"https:\/\/data-flair.training\/blogs\/author\/test001\/"}]}},"amp_enabled":true,"_links":{"self":[{"href":"https:\/\/data-flair.training\/blogs\/wp-json\/wp\/v2\/posts\/120186","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/data-flair.training\/blogs\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/data-flair.training\/blogs\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/data-flair.training\/blogs\/wp-json\/wp\/v2\/users\/86671"}],"replies":[{"embeddable":true,"href":"https:\/\/data-flair.training\/blogs\/wp-json\/wp\/v2\/comments?post=120186"}],"version-history":[{"count":6,"href":"https:\/\/data-flair.training\/blogs\/wp-json\/wp\/v2\/posts\/120186\/revisions"}],"predecessor-version":[{"id":134624,"href":"https:\/\/data-flair.training\/blogs\/wp-json\/wp\/v2\/posts\/120186\/revisions\/134624"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/data-flair.training\/blogs\/wp-json\/wp\/v2\/media\/132174"}],"wp:attachment":[{"href":"https:\/\/data-flair.training\/blogs\/wp-json\/wp\/v2\/media?parent=120186"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/data-flair.training\/blogs\/wp-json\/wp\/v2\/categories?post=120186"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/data-flair.training\/blogs\/wp-json\/wp\/v2\/tags?post=120186"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}