• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
North River Geographic Systems Inc

North River Geographic Systems Inc

Geospatial Problem Solving

  • Home
  • About NRGS
  • Training
  • Blog
  • Resources
    • QGIS Tutorials and Hacks
    • GDAL Tutorials and Hacks
    • PostGIS Tutorials and Hacks
    • GRASS Tutorials and Hacks
    • OSM Tutorials and Hacks
  • Services
    • Support and Services
    • Tennessee NG911 Address Server
    • Forestry Database Services
    • Conservation GIS
  • Portfolio
  • Show Search
Hide Search

FOSS4G

QGIS Process Command

I’m wrapping up the 2nd QGIS Class and have been digging hard into the python/scripting/programming side of QGIS. A programmer I am not and usually I have to pick some sort of path into the software that makes sense to me. Scripting has been coming up more and more as I dive back into the TN 911 Project.

I discovered something that’s been around for the last bit in qgis and I no doubt read the release notes on it……….and immediately forgot about it: qgis_process. You have a command line way to access QGIS Processing tools. My examples will be Linux oriented but it works on <fill in the blank>. Open a shell window and type qgis_process:

If I want a list of tools at my disposal: qgis_process list

If I want to know about a tool in particular: qgis_process help qgis:buffer

What if you want to run a command:

qgis_process run qgis:buffer –INPUT=parks_2274.shp DISTANCE=5000 –OUTPUT=parks_buffer.shp

….and if I check the output using QGIS:

Of course I did it all using shapefiles – I’ve got all the output file types I need at my disposal.

The nice thing is I have this uncomplicated way to access the processing tools and running them. Granted this isn’t Python but still – a command line way to access what you want to access. You could set up a very uncomplicated process to: Buffer -> Clip -> Merge -> Whatever you want without cracking open the desktop.

This points out two problems in my life:

  • Generally just keeping up. QGIS is an exciting side of life for me and one I enjoy. I really enjoy this because I started my life on the desktop with analysis and data cleanup. I’ll most likely end my career still enjoying that side of life – oh yeah Desktop GIS is dead I forgot.
  • Running a business is everything BUT the technical bells and whistles I enjoy. I need to make more time for that even if I have to block off a Friday morning for 2 hours and just buffer parks for no reason.

Trash and Input

I went canoeing. I picked up trash. Which wasn’t all that bad – I should have picked up more BUT it was a nice day to be floating down a creek.

Junk Boat

Anytime I get out in the canoe I do some thinking. Today ended up, worrying over the new QGIS class and this map I was making. I’m creating a map of canoe launches for a local county. I’m also using part of the map in the class. Which then led to “What if I find an new launch no one knows about?”. It happens. We found one that a high school had built and a known one that the National Park had closed.

I had talked about Input almost a year ago and left it more or less with “Awesome but slightly complicated” and granted it wasn’t complicated at all but the flow wasn’t quite there. There have been a ton of improvements. The flow is there now.

You have the option of creating a project out in the field. Last time I checked in on Input, the process was to build a project in QGIS and then syncing it through Lutra’s Mergin service. In my canoe (with very little cell service), I opened Input and went to “My Projects” and made a project that collected points. I decided to collect locations where we picked up tires. Luckily this wasn’t anything more than me goofing off because I usually don’t keep my phone out while canoeing. So I did a terrible job of data collection.

input Create Project Screen

From there I collected data and took some pics and started collecting data.

Input data collection screen

I took some pics. Made some notes. When I finished I synced it to Mergin. So here’s the cool thing. My Mergin Plugin in QGIS shows my project that I just synced. From there I can download it (and the photos) and display it on my desktop. The downloaded project comes as a geopackge.

QGIS 3.18 with Mergin

One of the nicer things about this endeavor is I can still keep collecting and sync back to my desktop at my convenience. If I make edits on the Desktop I can sync those back into Mergin. So you have this really nice back and forth with data collection: Input -> Mergin -> QGIS and QGIS -> Mergin -> Input. Next up is shoving those improvements into PostGIS directly.

Overall – Input has had a ton of changes for the better. Spur of the moment data collection worked. It makes me wonder on what else I can do. Which brings my grizzled old self back to how many options I have for my phone to go out and collect data. Yes in a lot of instances you need high accuracy data collection but in many cases (which is where I am in most of my professional life) a phone is it.

Fed Geo Day 2020 June 11th and 12th 2020

You know what I was going to do next week? Going to Washington DC and Teach a QGIS class.

You know what I’m doing now – Sitting in my house and teaching a class at Fed Geo Day on June 12th 2020

So what is Fed Geo Day:

———————————————————-

For decades open source software has been at the forefront of innovation in data collection, analysis, and visualization. Today, open source geospatial software has evolved into an “open ecosystem” of software, communities, and companies that enable field data collection and advanced visualization and lead the way in drone, lidar, IOT, and satellite imagery collection and analysis.

When open source software is combined with open standards for interoperability, government agencies have the most scalable, stable, secure and cost effective tools available to support activities including:

  • Empowering disadvantaged communities with limited funding
  • Enabling real-time data analysis at planetary scale
  • Optimizing release schedules for constituent facing tools

Join us for this one day conference in the heart of Washington DC. The morning plenaries will share how open source geospatial tools have become a critical part of operations within multiple federal agencies. The afternoon break out sessions will tackle technical and management solution use cases.


  • $20 dollars gets you into the conference
  • $20 dollars gets you into the QGIS Class. There are a lot of training options beyond the Introduction to QGIS class.

Attend! Support Open Source in the Federal Space!

QGIS and Editing: Widgets

I’ve been getting more questions lately on QGIS from all over the place. A pandemic will apparently: cause you to experiment with software, do some weird things with existing software, or call me up and ask “How do you work from home this sucks”. So one question started out with “I need to edit some data for the team and I need to keep up with what I edited and no it’s not in a database”.

In my perfect world you edit against postgresql/postgis and I set up some triggers to at the very least record who and when and possibly X and Y (or Y and X).  If you’re stuck with a shapefile, spatialite database, or Geopackage what can you do? So you have these things called widgets in QGIS……

So we’re going to play with a geopackage because that gives me some talking points for the next blog post. The ruggedly handsome client (me) has shoved some data into a geopackage. Geopackage has no login so I’m going to add my data to QGIS and do the following things:

  • Add two fields called ‘edituser’ and ‘editdate’
  • Set up two widgets in your QGIS Session.

If you right click on a data layer and go to properties you can set up a widget for your fields (under Attribute Forms). A widget can be a drop down list (something like a domain on a subtype for you over in ESRI Land).

So for the edituser field I will pick a simple text edit widget with a default value of ‘rjhale’ (At the Bottom of the menu).

The editdate field gets slightly more complicated. For that one I reach into the myriad of QGIS functions and pull out the $now. So I apply it as a default (and check that I want it to update if I move the line):

 

So moving forward I can at least keep up with “who” edited and “when”.

That’s possible the simplest use case of a widget you can have. What if you wanted to update the length of a line automatically? The QGIS Function is $length and you could apply that as a default to a widget on a field and have it calculate the length.

The big take away on this is you can do some very simple things to help your editing life. Two widgets with default values and you can keep up with what you’ve done (or maybe a co-worker) in an attempt to combine the data back together at a later time. A giant shoutout to Spatial Thoughts as I start to dive into more widget magic over the next bit.

 

Chattanooga QGIS Conference Update

So things are moving. Things are always a bit terrifying as this starts pulling together. I’ve been tossing updates everywhere – so here’s an update for the Blog.

Official Stuff

Website: https://wiki.osgeo.org/wiki/20191000-QGIS-US

Date: October 25th 2019

So the first big thing: A Social. I’m headed down to the Tap House this week to make sure everything is arranged for a social On October 24th.

Talks

Talks are rolling in for Friday. There is still room to submit a paper if you wish. The big one is I’m hopefully (and I’m at the mercy of the internet) is I’ve got Nyall Dawson on Video from Australia speaking first.

Here are some of the abstracts that have been submitted:

  • QGIS: It’s all about Form(s) – QGIS comes with the ability to create forms to help you input data or capture data. You can build simple forms to help users avoid misspellings and help speed up data capture. You can also build forms where data entry is dependent on previous data entered as well as forms where data entry depends on other GIS data. Building Forms in QGIS is easy, powerful, and easily done if you have no programming experience. I’m going to attempt to talk you through the easiest to make forms plus one difficult form to show you how easy this can be (or hard depending on how the demos work).
  • Using QGIS with TN’s 911 Database Standard – Henry County 911 recently moved away form their COTS system and started using QGIS, PostGIS, and Fulcrum to collect and maintain the county’s 911 data. This talk covers some of the in’s and out’s of switching software, tools, and workflows.
  • EcoValuator:  EcoValuator is built on python and provides a simple means of estimating the dollar value of a study area, based on the land cover types in that study area, and on your ecosystem service of choice. This presentation will cover background information about the project, what are ecosystem services, how the EcoValuator works, challenges of using the QGIS python API, and demonstration of the plugin in action.
  • Building a cloud-based mapping and analysis solution based on Openlayers and CesiumJS. 18 month ago our team felt the need for having a next Gen cloud mapping solution. We did not want to leave it all to ArcGIS Online, so we decided to build our own. It is designed to make maps, analyze data, add custom database solutions, and to share maps and data with fellow users.Take a look behind the scene of the journey of putting it all together and learn how far we have come and what are our ideas in terms of connecting Open Source solutions like QGIS and GeoServer.

…..and more are coming.

This is the third meeting I’ve put on since 2017. All meetings are centered around FOSS4G with this being the  first QGIS focused one. I’ve had emails and conversations from all over the US on this meeting. One thing that keeps coming up is people want more open source GIS meetings. The tough part is it has to be a community run affair or someone (yours truly) jumps up and puts this together. I really need to start earlier and shoot for bigger – BUT – there’s only so much I can do. We have the FOSS4G NA meetings that are well run and much bigger – but this seems to scratch an itch. How does this get bigger? I have no idea and I’m open to suggestions.

Anyway – the clock is ticking. The more the merrier at this thing so please make plans to attend.

 

 

Next Page »

Primary Sidebar

Calendar

July 2022
M T W T F S S
 123
45678910
11121314151617
18192021222324
25262728293031
« Jun    

What we talk about

addresses ArcGIS ASPRS Athens Atlanta Beer Cartography Chattanooga Community Conference Data Do Some Good Education ESRI Forestry FOSS4G foss4gna Fulcrum gaurisa ga urisa Gdal Georgia GeoServer GIS GISP Google GRASS Lidar MAGS open source OpenStreetMap osgeo OSM postgis Python QGIS raleigh Rambling Small Business Tennessee TNGIC Topology Training URISA usvi

North River Geographic Systems Inc

  • Home
  • About NRGS
  • Training
  • Blog
  • Resources
  • Services
  • Portfolio