﻿{"id":7023,"date":"2018-11-13T06:10:49","date_gmt":"2018-11-13T05:10:49","guid":{"rendered":"http:\/\/www.sigterritoires.fr\/?p=7023"},"modified":"2023-07-16T13:02:14","modified_gmt":"2023-07-16T11:02:14","slug":"geometry-validation-with-qgis-2-12-0","status":"publish","type":"post","link":"https:\/\/www.sigterritoires.fr\/index.php\/en\/geometry-validation-with-qgis-2-12-0\/","title":{"rendered":"Geometry validation with QGis 2.12.0"},"content":{"rendered":"\n<p>We have already discussed the geometry validation in a series of\narticles. Particularly, you can read the article <a href=\"https:\/\/translate.google.com\/translate?hl=en&amp;prev=_t&amp;sl=auto&amp;tl=en&amp;u=http:\/\/www.sigterritoires.fr\/index.php\/les-outils-de-validation-de-la-geometrie-5-avec-qgis\/\">The &nbsp;geometry validation &nbsp;tools (5) with QGis<\/a> for the validation tools with\nQGis 2.8<\/p>\n\n\n\n<p>Version 2.12 brings a new plugin that changes the game. Here is a list\nof&nbsp; those main characteristics . <\/p>\n\n\n\n<p>Firstly, let\u2019s see what does not change: there is no documentation regarding\nthe tools used by the plugin. It is true that in order to develop those tools implies\na very hard job, but using a tool without knowing what is actually done is not\nvery reassuring . <\/p>\n\n\n\n<!--more-->\n\n\n\n<p>We are going to proceed as for the aforementioned series of articles, by\ntaking a vector layer with errors and following the behaviour of the plugin. We\nwill be using the same working layer . <\/p>\n\n\n\n<p>\u00a0\u00bb &nbsp; We will use a layer of Italian communes provided by ISTAT,\nthe Italian Statistical Institute. This is the layer used in the geometry\nvalidation page of Spatialite: <a href=\"https:\/\/translate.google.com\/translate?hl=en&amp;prev=_t&amp;sl=auto&amp;tl=en&amp;u=https:\/\/www.gaia-gis.it\/fossil\/libspatialite\/wiki%3Fname%3Dliblwgeom-4.0\">SQL functions based on\nliblwgeom support &nbsp;version 4.0.0<\/a> . <\/p>\n\n\n\n<p>The layer is downloadable in this link:  . &nbsp; \u00a0\u00bb <\/p>\n\n\n\n<p>The QGis version used is 2.12.0 <\/p>\n\n\n\n<p><strong>Activation of the plugin<\/strong> <\/p>\n\n\n\n<p>The plugin is installed by default with version 2.12 but not activated .\nYou must activate it : <\/p>\n\n\n\n<p><strong><em>Extension -&gt; Install \/<\/em><\/strong> <strong><em>Manage<\/em><\/strong> <strong><em>Extensions<\/em><\/strong>\nthen check the box in front of <strong><em>Check geometry<\/em><\/strong> <\/p>\n\n\n\n<figure class=\"wp-block-image\"><img data-recalc-dims=\"1\" loading=\"lazy\" decoding=\"async\" width=\"525\" height=\"334\" data-attachment-id=\"7025\" data-permalink=\"https:\/\/www.sigterritoires.fr\/index.php\/en\/geometry-validation-with-qgis-2-12-0\/attachment\/131\/\" data-orig-file=\"https:\/\/i0.wp.com\/www.sigterritoires.fr\/wp-content\/uploads\/2018\/11\/131.png?fit=525%2C334&amp;ssl=1\" data-orig-size=\"525,334\" data-comments-opened=\"1\" data-image-meta=\"{&quot;aperture&quot;:&quot;0&quot;,&quot;credit&quot;:&quot;&quot;,&quot;camera&quot;:&quot;&quot;,&quot;caption&quot;:&quot;&quot;,&quot;created_timestamp&quot;:&quot;0&quot;,&quot;copyright&quot;:&quot;&quot;,&quot;focal_length&quot;:&quot;0&quot;,&quot;iso&quot;:&quot;0&quot;,&quot;shutter_speed&quot;:&quot;0&quot;,&quot;title&quot;:&quot;&quot;,&quot;orientation&quot;:&quot;0&quot;}\" data-image-title=\"131\" data-image-description=\"\" data-image-caption=\"\" data-large-file=\"https:\/\/i0.wp.com\/www.sigterritoires.fr\/wp-content\/uploads\/2018\/11\/131.png?fit=525%2C334&amp;ssl=1\" src=\"https:\/\/i0.wp.com\/www.sigterritoires.fr\/wp-content\/uploads\/2018\/11\/131.png?resize=525%2C334&#038;ssl=1\" alt=\"\" class=\"wp-image-7025\" srcset=\"https:\/\/i0.wp.com\/www.sigterritoires.fr\/wp-content\/uploads\/2018\/11\/131.png?w=525&amp;ssl=1 525w, https:\/\/i0.wp.com\/www.sigterritoires.fr\/wp-content\/uploads\/2018\/11\/131.png?resize=300%2C191&amp;ssl=1 300w\" sizes=\"auto, (max-width: 525px) 100vw, 525px\" \/><\/figure>\n\n\n\n<p><strong>Launching<\/strong> <strong>the plugin<\/strong> \n\nLoad the data layer you want to check and then\nclick the <strong><em>Vector<\/em><\/strong> menu <strong><em>-&gt;<\/em><\/strong><strong><em>Geometry<\/em><\/strong><strong><em>Tools<\/em><\/strong><strong><em>-&gt;<\/em><\/strong><strong><em>Check<\/em><\/strong><strong><em>geometries<\/em><\/strong><\/p>\n\n\n\n<figure class=\"wp-block-image\"><img data-recalc-dims=\"1\" loading=\"lazy\" decoding=\"async\" width=\"524\" height=\"247\" data-attachment-id=\"7026\" data-permalink=\"https:\/\/www.sigterritoires.fr\/index.php\/en\/geometry-validation-with-qgis-2-12-0\/attachment\/132\/\" data-orig-file=\"https:\/\/i0.wp.com\/www.sigterritoires.fr\/wp-content\/uploads\/2018\/11\/132.png?fit=524%2C247&amp;ssl=1\" data-orig-size=\"524,247\" data-comments-opened=\"1\" data-image-meta=\"{&quot;aperture&quot;:&quot;0&quot;,&quot;credit&quot;:&quot;&quot;,&quot;camera&quot;:&quot;&quot;,&quot;caption&quot;:&quot;&quot;,&quot;created_timestamp&quot;:&quot;0&quot;,&quot;copyright&quot;:&quot;&quot;,&quot;focal_length&quot;:&quot;0&quot;,&quot;iso&quot;:&quot;0&quot;,&quot;shutter_speed&quot;:&quot;0&quot;,&quot;title&quot;:&quot;&quot;,&quot;orientation&quot;:&quot;0&quot;}\" data-image-title=\"132\" data-image-description=\"\" data-image-caption=\"\" data-large-file=\"https:\/\/i0.wp.com\/www.sigterritoires.fr\/wp-content\/uploads\/2018\/11\/132.png?fit=524%2C247&amp;ssl=1\" src=\"https:\/\/i0.wp.com\/www.sigterritoires.fr\/wp-content\/uploads\/2018\/11\/132.png?resize=524%2C247&#038;ssl=1\" alt=\"\" class=\"wp-image-7026\" srcset=\"https:\/\/i0.wp.com\/www.sigterritoires.fr\/wp-content\/uploads\/2018\/11\/132.png?w=524&amp;ssl=1 524w, https:\/\/i0.wp.com\/www.sigterritoires.fr\/wp-content\/uploads\/2018\/11\/132.png?resize=300%2C141&amp;ssl=1 300w\" sizes=\"auto, (max-width: 524px) 100vw, 524px\" \/><\/figure>\n\n\n\n<p>The plugin settings window displays.\n\n\n\n<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img data-recalc-dims=\"1\" loading=\"lazy\" decoding=\"async\" width=\"525\" height=\"411\" data-attachment-id=\"7027\" data-permalink=\"https:\/\/www.sigterritoires.fr\/index.php\/en\/geometry-validation-with-qgis-2-12-0\/attachment\/133\/\" data-orig-file=\"https:\/\/i0.wp.com\/www.sigterritoires.fr\/wp-content\/uploads\/2018\/11\/133.png?fit=525%2C411&amp;ssl=1\" data-orig-size=\"525,411\" data-comments-opened=\"1\" data-image-meta=\"{&quot;aperture&quot;:&quot;0&quot;,&quot;credit&quot;:&quot;&quot;,&quot;camera&quot;:&quot;&quot;,&quot;caption&quot;:&quot;&quot;,&quot;created_timestamp&quot;:&quot;0&quot;,&quot;copyright&quot;:&quot;&quot;,&quot;focal_length&quot;:&quot;0&quot;,&quot;iso&quot;:&quot;0&quot;,&quot;shutter_speed&quot;:&quot;0&quot;,&quot;title&quot;:&quot;&quot;,&quot;orientation&quot;:&quot;0&quot;}\" data-image-title=\"133\" data-image-description=\"\" data-image-caption=\"\" data-large-file=\"https:\/\/i0.wp.com\/www.sigterritoires.fr\/wp-content\/uploads\/2018\/11\/133.png?fit=525%2C411&amp;ssl=1\" src=\"https:\/\/i0.wp.com\/www.sigterritoires.fr\/wp-content\/uploads\/2018\/11\/133.png?resize=525%2C411&#038;ssl=1\" alt=\"\" class=\"wp-image-7027\" srcset=\"https:\/\/i0.wp.com\/www.sigterritoires.fr\/wp-content\/uploads\/2018\/11\/133.png?w=525&amp;ssl=1 525w, https:\/\/i0.wp.com\/www.sigterritoires.fr\/wp-content\/uploads\/2018\/11\/133.png?resize=300%2C235&amp;ssl=1 300w\" sizes=\"auto, (max-width: 525px) 100vw, 525px\" \/><\/figure>\n\n\n\n<p>As you can see, the window includes several blocks of parameters . \n\nThese blocks correspond to the different types\nof geometry error supported by the plugin. Here is a graphic synthesis :\n\n\n\n<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img data-recalc-dims=\"1\" loading=\"lazy\" decoding=\"async\" width=\"525\" height=\"321\" data-attachment-id=\"7028\" data-permalink=\"https:\/\/www.sigterritoires.fr\/index.php\/en\/geometry-validation-with-qgis-2-12-0\/attachment\/134\/\" data-orig-file=\"https:\/\/i0.wp.com\/www.sigterritoires.fr\/wp-content\/uploads\/2018\/11\/134.png?fit=525%2C321&amp;ssl=1\" data-orig-size=\"525,321\" data-comments-opened=\"1\" data-image-meta=\"{&quot;aperture&quot;:&quot;0&quot;,&quot;credit&quot;:&quot;&quot;,&quot;camera&quot;:&quot;&quot;,&quot;caption&quot;:&quot;&quot;,&quot;created_timestamp&quot;:&quot;0&quot;,&quot;copyright&quot;:&quot;&quot;,&quot;focal_length&quot;:&quot;0&quot;,&quot;iso&quot;:&quot;0&quot;,&quot;shutter_speed&quot;:&quot;0&quot;,&quot;title&quot;:&quot;&quot;,&quot;orientation&quot;:&quot;0&quot;}\" data-image-title=\"134\" data-image-description=\"\" data-image-caption=\"\" data-large-file=\"https:\/\/i0.wp.com\/www.sigterritoires.fr\/wp-content\/uploads\/2018\/11\/134.png?fit=525%2C321&amp;ssl=1\" src=\"https:\/\/i0.wp.com\/www.sigterritoires.fr\/wp-content\/uploads\/2018\/11\/134.png?resize=525%2C321&#038;ssl=1\" alt=\"\" class=\"wp-image-7028\" srcset=\"https:\/\/i0.wp.com\/www.sigterritoires.fr\/wp-content\/uploads\/2018\/11\/134.png?w=525&amp;ssl=1 525w, https:\/\/i0.wp.com\/www.sigterritoires.fr\/wp-content\/uploads\/2018\/11\/134.png?resize=300%2C183&amp;ssl=1 300w\" sizes=\"auto, (max-width: 525px) 100vw, 525px\" \/><\/figure>\n\n\n\n<p>The first one includes the basic elements of geometries validation: the\nauto-intersections, the duplicated nodes and the polygons with less than three\nnodes (not shown in the previous image). <\/p>\n\n\n\n<p>In the second block you must choose the type of geometry to validate\n(point, line , polygon , &#8230; ). <\/p>\n\n\n\n<p>The third block corresponds to the management of the holes and\narchipelagos. You authorize the polygons with holes or not, according to your\nknowledge of the data , and you authorize archipelagos polygons or not. <\/p>\n\n\n\n<p>The fourth block used to validate data according to minimal parameters of\nsegment length, angle, area and width. It becomes obvious that a deeper\nknowledge of the data is essential to configure these parameters . <\/p>\n\n\n\n<p>The last block allows topological validation , by looking for\nduplicates, entities within other entities , partial entities overlays and\ninterstices between entities . <\/p>\n\n\n\n<p><strong>Plugin test<\/strong> \n\nFirstly, let\u2019s test a simple configuration, only\ntaking in account the geometry validity (first block of parameters ), to\ncompare the result with the tools of previous QGis versions. &nbsp;\n\n\n\n<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img data-recalc-dims=\"1\" loading=\"lazy\" decoding=\"async\" width=\"525\" height=\"410\" data-attachment-id=\"7029\" data-permalink=\"https:\/\/www.sigterritoires.fr\/index.php\/en\/geometry-validation-with-qgis-2-12-0\/attachment\/135\/\" data-orig-file=\"https:\/\/i0.wp.com\/www.sigterritoires.fr\/wp-content\/uploads\/2018\/11\/135.png?fit=525%2C410&amp;ssl=1\" data-orig-size=\"525,410\" data-comments-opened=\"1\" data-image-meta=\"{&quot;aperture&quot;:&quot;0&quot;,&quot;credit&quot;:&quot;&quot;,&quot;camera&quot;:&quot;&quot;,&quot;caption&quot;:&quot;&quot;,&quot;created_timestamp&quot;:&quot;0&quot;,&quot;copyright&quot;:&quot;&quot;,&quot;focal_length&quot;:&quot;0&quot;,&quot;iso&quot;:&quot;0&quot;,&quot;shutter_speed&quot;:&quot;0&quot;,&quot;title&quot;:&quot;&quot;,&quot;orientation&quot;:&quot;0&quot;}\" data-image-title=\"135\" data-image-description=\"\" data-image-caption=\"\" data-large-file=\"https:\/\/i0.wp.com\/www.sigterritoires.fr\/wp-content\/uploads\/2018\/11\/135.png?fit=525%2C410&amp;ssl=1\" src=\"https:\/\/i0.wp.com\/www.sigterritoires.fr\/wp-content\/uploads\/2018\/11\/135.png?resize=525%2C410&#038;ssl=1\" alt=\"\" class=\"wp-image-7029\" srcset=\"https:\/\/i0.wp.com\/www.sigterritoires.fr\/wp-content\/uploads\/2018\/11\/135.png?w=525&amp;ssl=1 525w, https:\/\/i0.wp.com\/www.sigterritoires.fr\/wp-content\/uploads\/2018\/11\/135.png?resize=300%2C234&amp;ssl=1 300w\" sizes=\"auto, (max-width: 525px) 100vw, 525px\" \/><\/figure>\n\n\n\n<p>The number of detected errors is 476. This figure must be compared to\nthose obtained in previous tests : <\/p>\n\n\n\n<p>Display items  Search : <\/p>\n\n\n\n<figure class=\"wp-block-table\"><table><thead><tr><td>     <\/td><\/tr><tr><td>\n   <strong>Software<\/strong> \n   <\/td><td>\n   <strong>&nbsp;<\/strong>\n   <\/td><td>\n   <strong>Nb<\/strong> <strong>errors<\/strong> <strong>found<\/strong> \n   <\/td><\/tr><\/thead><tbody><tr><td>\n  ArcGis\n  10.3.1 \n  <\/td><td>\n  &nbsp;\n  <\/td><td>\n  0 \n  <\/td><\/tr><tr><td>\n  SpatiaLite\n  \n  <\/td><td>\n  &nbsp;\n  <\/td><td>\n  19 \n  <\/td><\/tr><tr><td>\n  <a href=\"https:\/\/www.sigterritoires.fr\/index.php\/en\/starting-with-postgres-postgis\/\">postgis<\/a>\n  \n  <\/td><td>\n  &nbsp;\n  <\/td><td>\n  19 \n  <\/td><\/tr><tr><td>\n  FME\n  2015 \n  <\/td><td>\n  &nbsp;\n  <\/td><td>\n  19 \n  <\/td><\/tr><tr><td>\n  Geomedia\n  \n  <\/td><td>\n  &nbsp;\n  <\/td><td>\n  28 \n  <\/td><\/tr><tr><td>\n  Qgis\n  2.8 \n  <\/td><td>\n  Verify\n  topol . \n  <\/td><td>\n  19 \n  <\/td><\/tr><tr><td>\n  &nbsp;\n  <\/td><td>\n  Valid.\n  Geom . \n  <\/td><td>\n  129 \n  <\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<p>Viewing\nitems 1 to 7 of 7 items <\/p>\n\n\n\n<p>Previous\nNext <\/p>\n\n\n\n<p>Being 4 times larger than those observed with the geometry validation\ntool available in QGis 2.8 it would be interesting to see what are these new\nerrors detected . <\/p>\n\n\n\n<p>Nevertheless, the only &nbsp;available indication\nis the name of the error : Type of geometry <\/p>\n\n\n\n<p>( multipolygon ) and the coordinates of the centroid of the polygon\nconcerned . <\/p>\n\n\n\n<p>Despite the efforts deployed, it was impossible to see the errors in\nmost communes indicated as error . <\/p>\n\n\n\n<p>Therefore, we have tried the automatic correction options of the plugin\nbut despite the installation on several positions with different systems and\nconfigurations, we have got a QGis crash with every attempt of correction. <\/p>\n\n\n\n<p><strong>Conclusions<\/strong> <\/p>\n\n\n\n<p>The plugin appears be more effective in the detection of geometry errors\n, but it presents, in its current stage of development two major problems: <\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>a lack of accurate location of the error for the\nconcerned geometry concerned <\/li>\n\n\n\n<li>a regular crash of the automatic correction module . <\/li>\n<\/ul>\n\n\n\n<p><strong>To<\/strong> <strong>follow<\/strong> <strong>with<\/strong> <strong>interest, as<\/strong> <strong>it<\/strong> <strong>looks&nbsp; very<\/strong> <strong>promising<\/strong> <strong>.<\/strong> <\/p>\n","protected":false},"excerpt":{"rendered":"<p>We have already discussed the geometry validation in a series of articles. Particularly, you can read the article The &nbsp;geometry validation &nbsp;tools (5) with QGis for the validation tools with QGis 2.8 Version 2.12 brings a&hellip;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"give_campaign_id":0,"_bbp_topic_count":0,"_bbp_reply_count":0,"_bbp_total_topic_count":0,"_bbp_total_reply_count":0,"_bbp_voice_count":0,"_bbp_anonymous_reply_count":0,"_bbp_topic_count_hidden":0,"_bbp_reply_count_hidden":0,"_bbp_forum_subforum_count":0,"sfsi_plus_gutenberg_text_before_share":"","sfsi_plus_gutenberg_show_text_before_share":"","sfsi_plus_gutenberg_icon_type":"","sfsi_plus_gutenberg_icon_alignemt":"","sfsi_plus_gutenburg_max_per_row":"","_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_post_was_ever_published":false},"categories":[1260],"tags":[],"class_list":["post-7023","post","type-post","status-publish","format-standard","hentry","category-non-classe-en"],"aioseo_notices":[],"jetpack_featured_media_url":"","jetpack_shortlink":"https:\/\/wp.me\/p6XU0A-1Ph","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/www.sigterritoires.fr\/index.php\/wp-json\/wp\/v2\/posts\/7023","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.sigterritoires.fr\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.sigterritoires.fr\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.sigterritoires.fr\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.sigterritoires.fr\/index.php\/wp-json\/wp\/v2\/comments?post=7023"}],"version-history":[{"count":0,"href":"https:\/\/www.sigterritoires.fr\/index.php\/wp-json\/wp\/v2\/posts\/7023\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.sigterritoires.fr\/index.php\/wp-json\/wp\/v2\/media?parent=7023"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.sigterritoires.fr\/index.php\/wp-json\/wp\/v2\/categories?post=7023"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.sigterritoires.fr\/index.php\/wp-json\/wp\/v2\/tags?post=7023"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}