Subscribe to this thread
Home - General / All posts - building footprint : .parquet to manifold9
Corentin
164 post(s)
#09-Oct-24 08:26

Hello,

it is possible to download there https://beta.source.coop/vida/google-microsoft-osm-open-buildings/geoparquet/by_country/ building footprints for entire countries

for a small country like Benin 6millions shapes are available. according to https://medium.com/vida-engineering/updating-the-ultimate-cloud-native-building-footprints-dataset-6d4384cb93c4

several format are available. to my knowledge none of them can be read by M9 (pmtiles, .parquet, .flatgeobuf).

some month ago I tried to use a python package though M9 (I don't remember which one) to be able to use those formats in M9, very complicated, not fully working, not fully supported.

My workflow is now the following :

1. download .parquet

2. open in QGIS

3. use qGIS to export to .Sqlite

4. import the .Sqlite in M9

first question => is .sqlite the best format in term of performance to transform from .parquet to something M9 can read?

then I need to select a subset of these building (like all buildings in a 10km radius around 10 cities):

I did the following, but it seemed a bit non-optimal

  1. I draw my buffers in M9,
  2. I did a spatial join to copy the mfd_id column of the buffers to the building drawing
  3. select entries where mfd_id_buffer was not null (I want to keep the whole dataset intact for later use!)
  4. copy selected items
  5. past as new table (~100 000 items)
  6. export to .shp for later import in Manifold8

my second question is to know if there is a better way to extract these 100k items to open in M8 ?

Thank you for your help!

rk
641 post(s)
#09-Oct-24 08:44

Manifold should be able to use GDAL to link/import (Geo)Parquet directly.

Setting up GDAL for Manifold may be a bit tricky. I'm happy to help later.

GDAL 3.7.x is the latest that Manifold supports, (Geo)Parquet was added to GDAL 3.5.

Corentin
164 post(s)
#09-Oct-24 08:57

exactly => GDAL 3.7 => didn't work for me (I am stuck with an older version, I cannot remove the old versino to install the new one). I spent more time trying to install it than using it though qGIS.

I need to explain to colleagues how to use these building footprint database. They are not skilled in python and installing GDAL on their laptop will be too complicated...

It is much easier to tell them, "install qGIS, import in .parquet, export in [whatever M9 can read]" than to tell them to install GDAL.

rk
641 post(s)
#09-Oct-24 14:58

I had a nice success

2024-10-09 17:53:07 -- Load library: C:\Manifold-9-Edge\gdal\gdal307.dll

2024-10-09 17:53:08 -- (import) Driver: Parquet ((Geo)Parquet)

2024-10-09 17:53:29 -- Import: C:\Downloads\EST.parquet (22.825 sec)

148 MB 1134355 footprints

I will make a tutorial of how to set up GDAL in "portable" mode. Not depending on installed QGIS or such.

Manifold User Community Use Agreement Copyright (C) 2007-2021 Manifold Software Limited. All rights reserved.