<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Ahsan Mukhtar on Medium]]></title>
        <description><![CDATA[Stories by Ahsan Mukhtar on Medium]]></description>
        <link>https://medium.com/@ahsanmukhtar02?source=rss-f3d37c7a8321------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/0*UldZp-nH25BBYp0p.</url>
            <title>Stories by Ahsan Mukhtar on Medium</title>
            <link>https://medium.com/@ahsanmukhtar02?source=rss-f3d37c7a8321------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Thu, 19 Nov 2026 20:35:45 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@ahsanmukhtar02/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[QGIS Plugin development (Installation and Configuration) on Windows]]></title>
            <link>https://medium.com/@ahsanmukhtar02/qgis-plugin-development-installation-and-configuration-on-windows-822af090df58?source=rss-f3d37c7a8321------2</link>
            <guid isPermaLink="false">https://medium.com/p/822af090df58</guid>
            <category><![CDATA[qgis3]]></category>
            <category><![CDATA[qgis]]></category>
            <category><![CDATA[gis-development]]></category>
            <category><![CDATA[geospatial]]></category>
            <category><![CDATA[gis]]></category>
            <dc:creator><![CDATA[Ahsan Mukhtar]]></dc:creator>
            <pubDate>Tue, 28 May 2019 05:38:39 GMT</pubDate>
            <atom:updated>2020-07-30T11:06:13.171Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/795/0*BxIhheauzl_ctr4A.png" /></figure><ul><li>Download the QGIS and install it on your machine. Use the default Configurations, it will install the QGIS in <strong>C:\Program Files</strong> on windows.</li><li>After installing QGIS Desktop, run it from the Start Menu.</li><li>Close the tips that you will see after QGIS has been started</li><li>Once QGIS is open, You will see a lot of icons on the top bar and menu in QGIS. Every option represent a different functionality of QGIS and Geo-spatial functionality.</li><li>From the Menu bar, Go to Plug-ins Menu, and in the plug-ins menu you will see an option of <strong>“Manage and Install Plug-ins”.</strong> Click on it, and it will fetch repositories that is provided where all contributed plug-ins are available.</li></ul><p>Plug-ins Menu</p><ul><li>After installation and creating of new plug-in go to Manage and install plugin again, and install a new plug-in “<strong>Plugin Reloader”</strong>. Plug-in Reloader helps to re-compile plug-ins within QGIS, without QGIS to be restarted</li><li>Now go to start menu and type <strong>OSGEO, </strong>it will open a shell. This is default installed with QGIS. In case if you have multiple OSGEO, i would recommend that you use the one that is installed with QGIS.</li><li>In the shell type below command where the path is the one where plugin is installed/saved.</li></ul><p>Download and Install Plugin Window</p><ul><li>Your OSGEO shell will now point to plug-in directory.</li><li>Run this command in that directory</li><li>Install “Python Builder plug-in”.</li><li>After the installation of the Python builder plug-in, You will see an icon in QGIS for Python Builder plug-in</li><li>Click on the icon, that will open a dialogue box, fill in all the information that is required, for the Python Builder. For more about Python Builder plug-in, you can check this <a href="http://www.qgistutorials.com/en/docs/building_a_python_plugin.html">Tutorial and Tips</a></li><li>Save your new QGIS plug-in into</li><li>If no error is shown in the shell, then everything is fine and the plugin’s resources are successfully compiled.</li><li>Restart QGIS.</li><li>Now go to <strong>“Manage and install</strong> <strong>plug-in”</strong> from the menu bar under plug-ins.</li><li>Go to Installed plug in from left sidebar.</li><li>Click on the check-box of the Plug-in, that has the name you provided on creation of it.</li><li>If there is not warning or error, you are good to go.</li><li>New plugin with default icon will now be visible on QGIS interface.</li><li>You can click on it, to see an empty interface, this is because you have not added any functionality of it.</li></ul><p><strong>Development of the Plug-in:</strong></p><blockquote><em>C:\Program Files\QGIS 2.xx\apps\qgis\python\plugins</em></blockquote><blockquote><em>cd C:\Program Files\QGIS 2.18\apps\qgis\python\plugins\{PluginName}</em></blockquote><blockquote><em>C:\Users\User name\.qgis2\python\plug-ins</em></blockquote><blockquote><em>pyrcc4 -o resources.py resources.qrc</em></blockquote><p>You can use QT Designer that is also installed with QGIS, to develop an interface of the plug-in, using the .ui file that is created with the Python Builder. For more about the development of the plug-in, methods, modules and libraries you can Follow <a href="http://www.qgistutorials.com/en/">QGIS Tutorial and Tips</a>, where from you can get good detail description about the plug-in development. You can also can detail about coding methods that will be used for the plug-ins. The whole development wander around PyQt4, Python2.7 and <a href="https://docs.qgis.org/2.14/en/docs/pyqgis_developer_cookbook/">PyQGIS</a></p><p>QGIS development, more specifically QGIS plug-in development has always been a helpful procedure. QGIS plug-ins can help you automate complex tasks, and reduce redundant effort that is involved in your daily work. Anyone with basic background of QGIS and Python can build their own plug-ins, and you can bring any idea in the form of plug-ins.You can bring and Statistical, Geo-statistical, Database DDL/DML operations into one platform.</p><p><em>Originally published at </em><a href="https://medium.com/@ahsanmukhtar02/qgis-plugin-development-installation-and-configuration-on-windows-d70eab25e2f1"><em>https://medium.com</em></a><em> on May 28, 2019.</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=822af090df58" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[ESRI’s Tile Cache (Compact Tile Cache) Visualization in Open Source ( QGIS)]]></title>
            <link>https://medium.com/@ahsanmukhtar02/esris-tile-cache-compact-tile-cache-visualization-in-open-source-qgis-eeb385b85ea3?source=rss-f3d37c7a8321------2</link>
            <guid isPermaLink="false">https://medium.com/p/eeb385b85ea3</guid>
            <category><![CDATA[tiling]]></category>
            <category><![CDATA[qgis]]></category>
            <category><![CDATA[esri]]></category>
            <category><![CDATA[gis]]></category>
            <category><![CDATA[cache]]></category>
            <dc:creator><![CDATA[Ahsan Mukhtar]]></dc:creator>
            <pubDate>Sun, 17 Feb 2019 07:03:32 GMT</pubDate>
            <atom:updated>2019-02-17T07:03:32.769Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/678/1*Z5VlXojgexQNmuJt3PUhjA.png" /></figure><p>I was working on a project, where we were migrating all of geospatial technology stacks from Proprietary software to Open Source. Our Goal was to provide a complete and end to end open source GIS solution.</p><p><a href="https://www.esri.com/en-us/home">ESRI</a> has been providing GIS services for more than 3 decades and has pioneered many GIS solutions, so it was never an easy challenge to replace their environment, and specially we had to convert their own file formats and supported data sets, so that we could visualize them, edit and analyze them in Open Source GIS Software. We had faced many challenges during this project, and have done many successful migrations from ESRI to Open Source.</p><p>Here I would like to share my experience that i had found most difficult to migrate to Open Source. The Problem we had was visualization of ESRI’s created Tile Cache Data in Open Source Software (<a href="https://www.qgis.org/en/site/">QGIS</a>). <a href="https://www.qgis.org/en/site/">QGIS</a> is an Open Source, freely available GIS Software that is also considered as an alternative to ArcMap. Both have their pros and cons other than cost. So, our end goal was to visualize ESRI’s created tile cache data in QGIS. There were some help available online, but none of them was useful, as that was misleading or incomplete.</p><h3>What are ESRI’s Cached Tiles?</h3><p>ESRI provide cache based web and desktop services. You can publish an Cache service on ArcGIS for Server, and also host Cache on your desktop and then visualize them in ArcMap. ESRI’s cached tiles are Cached images at different zoom levels as per defined in Caching Scheme.</p><p>ESRI provides a complete set of tool for creating, importing, exporting, removing and updating of tiles. These tools are capable of generating cache tiles from a raster data set, vector data set, a mosaic data set, or a map document locally on your desktop without the need for ArcGIS Server. These tiles caches can then be shared as tile packages that is supported on multiple online and desktop platforms and can be published as a tiled map service. ESRI’s provided tile cache are categorized into two types</p><ul><li><strong>Compact</strong> — In compact format, each file in the cache contains a bundle of tiles. The bundles are 128 tiles wide by 128 tiles high, containing a maximum of 16,384 tiles. Compact caches copy much faster than exploded caches, and they take less space on disk.</li><li><strong>Exploded</strong> — In exploded format, each tile is stored as a file on disk. This makes it easier to see the tiles in your cache; however, it results in larger caches that take longer to create and can be cumbersome to copy.</li></ul><p>The enormous number of files and folders in the cache can sometimes cause inefficiencies in copying utilities, including Windows Copy/Paste. For this reason, compact caches greatly reduce cache copying time. If you have an automatic cache update workflow that creates tiles on a staging server and copies them to a production server, it’s recommended that you use compact caches. Additionally, if you have limited disk space available, you should use compact caches.</p><p>We already had Gigs of Bytes of data in Compact cache format, with 10 levels of cache, and had to visualize them in QGIS.</p><p>After a lot of effort we came to two ways to resolve problem of visualizing ESRI’s Tile Cache in QGIS.</p><p>1- Visualize through GeoServer’s extension</p><p>2- Create Geospatial SQL-Lite Database</p><h3>Visualize through GeoServer’s extension</h3><p><a href="http://geowebcache.org/">GeoWebCache</a> is a Java web Application, that is used to host the tiles created through ESRI. Here is detailed <a href="http://geowebcache.org/docs/1.8.0/configuration/layers/arcgistilingschemes.html">Tutorial</a> available on Boundless Website. But this could not resolve my problem because of:</p><p>1- Very poor documentation</p><p>2- GeoWebCache distribution’s starange behavior towards the deployment of Tile Cache.</p><p>So, this left us nowhere after investing a week of time in GeoWebCache, as the documentation is very poor, and finding some false information as well related to this.</p><p>So, we decided to move to second option to create a geospatial SQL-lite database and then visualize that in QGIS</p><h3>Create Geospatial SQL-Lite Database</h3><p><a href="https://www.geopackage.org/">GeoPackage</a> is an open source plateform independent, portable, self describle, and compact format for transformation of geospatial information. Fortunately, QGIS provides support for GeoPackages, the complete process to convert <strong>ESRI’S Compact Cache Tiles to GeoPackage</strong> consists of different steps. I will explain it step by step</p><p>1- We took sample ESRI’s Compact Cache Tile sample of around 230MB of size.</p><p>2- We used <a href="http://desktop.arcgis.com/en/arcmap/10.3/tools/data-management-toolbox/export-tile-cache.htm"><strong>Export Tile Cache</strong></a> tool that is available in ArcGIS Desktop, to convert the compact tile cache into Exploded tiles. We are using ArcGIS 10.4.1 version. In this tool, we provided Exploded paramater for output tiles type</p><p>3- This tool basically created PNGs of the compact cache, with different folder, for each extent level.</p><p>4- We had found a repository on the github, that uses this exploded Tilecache data and then convert it into geopackage. Although there were few errors with the code and we fixed those errors. The complete code was written in Python, so it was easy to modify.</p><p>5- Mostly errors were related to the data types with it, specifically for the coordinates.</p><p>All of the code and instructions are available at this repository</p><p><a href="https://github.com/GitHubRGI/geopackage-python/wiki/Usage-Instructions-for-tiles2gpkg_parallel.py">https://github.com/GitHubRGI/geopackage-python/wiki/Usage-Instructions-for-tiles2gpkg_parallel.py</a></p><p>6- After that it created GeoPackage file of size 230MB, that was ready to be added into QGIS</p><p>7- In QGIS, under the database tab, there is DbManager utility available. Click on DbManager it will provide you multiple database connectivity options.</p><p>8- From the Databases available select GeoPackage and browse to the path of GeoPackage.</p><p>9- After that add the layer that is shown in the QGIS. You will now be able to vsiualize and its behavior will be same as cached layer is added to ArcMap.</p><p>Cheers!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=eeb385b85ea3" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[QGIS Plugin development (Installation and Configuration) on Windows]]></title>
            <link>https://medium.com/@ahsanmukhtar02/qgis-plugin-development-installation-and-configuration-on-windows-d70eab25e2f1?source=rss-f3d37c7a8321------2</link>
            <guid isPermaLink="false">https://medium.com/p/d70eab25e2f1</guid>
            <category><![CDATA[gis]]></category>
            <category><![CDATA[plugins]]></category>
            <category><![CDATA[development]]></category>
            <category><![CDATA[qgis]]></category>
            <category><![CDATA[python]]></category>
            <dc:creator><![CDATA[Ahsan Mukhtar]]></dc:creator>
            <pubDate>Fri, 09 Feb 2018 23:15:06 GMT</pubDate>
            <atom:updated>2019-05-28T05:38:39.672Z</atom:updated>
            <cc:license>http://creativecommons.org/licenses/by/4.0/</cc:license>
            <content:encoded><![CDATA[<p>I have experience of more than a year in QGIS Plug-in development, and I have developed variety of plug-ins for spatial data management, geospatial data visualization, spatial data analytics and spatial data editing. This is also my first story on medium and I will share the gist of my experience and proper guideline to start QGIS Plugins development.</p><p>I have noticed that whenever somebody is starting QGIS Plug-in development in QGIS, it is very difficult to find easy to follow documentation to install and configure QGIS plug-ins, particularly in case of windows for newbies and that is why they always stuck at some point in installation and configuration of QGIS plug-ins. That is why i decided to share my experience for developing QGIS Plug-ins, because i have been building a lot of QGIS plug-ins on windows, and i believe that this might help to save time for installing and configuring QGIS Plug-in environment.</p><p><strong>A little about QGIS</strong></p><p>QGIS is a free and open source desktop cross platform application that supports visualization, editing and analysis of geospatial data. Some people find QGIS to be alternative to a famous Enterprise solution ArcGIS. But both have their own pros and cons. I will not go into debate of which of them is good or bad and for what purpose. For more detailed comparison between these you can check <a href="http://gisgeography.com/qgis-arcgis-differences/">ArcGIS vs QGIS comparison</a></p><p><strong>QGIS Plug-ins:</strong></p><p>QGIS Plugins are extension to QGIS, in order to extend the functionalities of QGIS and develop custom logics that can be used to interrogate Geo-spatial data. When you will install the QGIS, you will see the list of some plug-ins already available. These are the plug-ins that you get on installing the QGIS. QGIS Plug-ins can also be downloaded from on-line repository of QGIS, where people have shared their contributions for public use. You can check <a href="https://plugins.qgis.org/plugins/">Repository of Plug-in</a>, to see available plug-ins.</p><h3><strong>Creating and Configuring QGIS Plug-in:</strong></h3><p>For installation and configuration of QGIS plugin you need to have basic understanding of QGIS and Python(2.7):</p><p>You also need to install:</p><ol><li>QGIS: QGIS can easily be downloaded and installed from <a href="https://qgis.org/en/site/forusers/download.html">here</a><a href="https://qgis.org/en/site/forusers/download.html.">.</a> Make sure that you selected the appropriate version according to operating system. For this tutorial we are focusing on window’s version.</li><li>Text Editor:You will need to have a text editor for editing the code of . Plug-in. There are many text editors available e.g. Sublime, Notepad++, PyCharm. You may choose as per your reference</li></ol><p><strong>Steps to Successful Creation of Plug-in:</strong></p><ul><li>Download the QGIS and install it on your machine. Use the default Configurations, it will install the QGIS in <strong>C:\Program Files</strong> on windows.</li><li>After installing QGIS Desktop, run it from the Start Menu.</li><li>Close the tips that you will see after QGIS has been started</li><li>Once QGIS is open, You will see a lot of icons on the top bar and menu in QGIS. Every option represent a different functionality of QGIS and Geo-spatial functionality.</li><li>From the Menu bar, Go to Plug-ins Menu, and in the plug-ins menu you will see an option of <strong>“Manage and Install Plug-ins”.</strong> Click on it, and it will fetch repositories that is provided where all contributed plug-ins are available.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/669/1*j8ucb955Acc5pwaonNJITg.jpeg" /><figcaption>Plug-ins Menu</figcaption></figure><ul><li>Click on “Manage and install Plug-in”, it will open a dialogue box of Plug-ins. In the Search box, search for “Plug-in Builder”. Plug-in Builder is QGIS plug-in, that is available within QGIS repository, the main purpose of this plug-in is to provide a basic structure or template for development of further development of the plug-ins.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/795/1*3FIg0yyQd-N6_Osy3FoEJQ.png" /><figcaption>Download and Install Plugin Window</figcaption></figure><ul><li>Install “Python Builder plug-in”.</li><li>After the installation of the Python builder plug-in, You will see an icon in QGIS for Python Builder plug-in</li><li>Click on the icon, that will open a dialogue box, fill in all the information that is required, for the Python Builder. For more about Python Builder plug-in, you can check this <a href="http://www.qgistutorials.com/en/docs/building_a_python_plugin.html">Tutorial and Tips</a></li><li>Save your new QGIS plug-in into</li></ul><blockquote>C:\Program Files\QGIS 2.xx\apps\qgis\python\plugins</blockquote><ul><li>After installation and creating of new plug-in go to Manage and install plugin again, and install a new plug-in “<strong>Plugin Reloader”</strong>. Plug-in Reloader helps to re-compile plug-ins within QGIS, without QGIS to be restarted</li><li>Now go to start menu and type <strong>OSGEO, </strong>it will open a shell. This is default installed with QGIS. In case if you have multiple OSGEO, i would recommend that you use the one that is installed with QGIS.</li><li>In the shell type below command where the path is the one where plugin is installed/saved.</li></ul><blockquote>cd C:\Program Files\QGIS 2.18\apps\qgis\python\plugins\{PluginName}</blockquote><ul><li>You may also install the plug-in to below path as well, but in this case that plug-in will be accessible to only that one user that has created the plugin.</li></ul><blockquote>C:\Users\User name\.qgis2\python\plug-ins</blockquote><ul><li>Your OSGEO shell will now point to plug-in directory.</li><li>Run this command in that directory</li></ul><blockquote>pyrcc4 -o resources.py resources.qrc</blockquote><ul><li>If no error is shown in the shell, then everything is fine and the plugin’s resources are successfully compiled.</li><li>Restart QGIS.</li><li>Now go to <strong>“Manage and install</strong> <strong>plug-in”</strong> from the menu bar under plug-ins.</li><li>Go to Installed plug in from left sidebar.</li><li>Click on the check-box of the Plug-in, that has the name you provided on creation of it.</li><li>If there is not warning or error, you are good to go.</li><li>New plugin with default icon will now be visible on QGIS interface.</li><li>You can click on it, to see an empty interface, this is because you have not added any functionality of it.</li></ul><p><strong>Development of the Plug-in:</strong></p><p>You can use QT Designer that is also installed with QGIS, to develop an interface of the plug-in, using the .ui file that is created with the Python Builder. For more about the development of the plug-in, methods, modules and libraries you can Follow <a href="http://www.qgistutorials.com/en/">QGIS Tutorial and Tips</a>, where from you can get good detail description about the plug-in development. You can also can detail about coding methods that will be used for the plug-ins. The whole development wander around PyQt4, Python2.7 and <a href="https://docs.qgis.org/2.14/en/docs/pyqgis_developer_cookbook/">PyQGIS</a></p><p>QGIS development, more specifically QGIS plug-in development has always been a helpful procedure. QGIS plug-ins can help you automate complex tasks, and reduce redundant effort that is involved in your daily work. Anyone with basic background of QGIS and Python can build their own plug-ins, and you can bring any idea in the form of plug-ins.You can bring and Statistical, Geo-statistical, Database DDL/DML operations into one platform.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=d70eab25e2f1" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>