Import/Catalogue/Brazil Funai Import

From OpenStreetMap Wiki
Jump to navigation Jump to search

Import Plan Outline


This import will incorporate Brazilian indigenous land boundaries, as published by Fundação Nacional do Índio (Funai), into OSM.

Import Data

The import data is available at the Funai website [1]. No licensing information is provided at that site, but a freedom of information request revealed that the data is the public domain (see this talk-br thread).

OSM Data Files

This import is in progress. If you are interested in contributing, see WikiProject Brazil/Terras indígenas.

The osm files are available here.

Import Type

This is a one-time import and will be made using JOSM. Future updates to indigenous lands will be made using the law creating them.

Data Preparation

Data Reduction & Simplification

Tagging Plans

Indigenous lands will be tagged following the scheme in boundary=protected_area. Since the tag boundary=protected_area itself is not yet rendered, it will be replaced by the combination boundary=national_park and a leisure=nature_reserve, following the current practice in Brazil and other places. Also, a key ref:Funai=* will hold the protected area's id number in the original dataset.

Tagging will be as follows

protection_title=[Terra indígena|Reserva indígena]
ref:Funai=<id number>
operator=Fundação Nacional do Índio

Changeset Tags

comment=Funai import

Data Transformation

ogr2osm will be used to convert the shapefiles into osm format. The translation script is below.

# -*- coding: utf-8 -*-
import re
def filterFeature(ogrfeature, fieldNames, reproject):
    if not ogrfeature:

    if ogrfeature.GetFieldAsString('fase_descr') in ['Homologada', 'Regularizada']:
        return ogrfeature
def filterTags(attrs):
    if not attrs:
    tags = {}
    if attrs['tipo_terra'] == u'Terra Indígena':
        tags['protection_title'] = u'Terra indígena'
        tags['name'] = u'Terra Indígena ' + attrs['terrai_nom']
    elif attrs['tipo_terra'] == u'Reserva Indígena':
        tags['protection_title'] = u'Reserva indígena'
        tags['name'] = u'Reserva Indígena ' + attrs['terrai_nom']
        print ">>> unrecognized type", + attrs['tipo_terra']
    tags['boundary'] = 'national_park'
    tags['leisure'] = 'nature_reserve'
    tags['protect_class'] = '24'
    tags['ref:Funai'] = '{:d}'.format(int(float(attrs['terrai_cod'])))
    tags['operator'] = u'Fundação Nacional do Índio'
    tags['ownership'] = 'national'
    tags['source'] = "Funai"

    return tags


Conflation was be manual. The changesets involved in the import are listed below.

File Status Changesets Notes
funai-amazonas-1.osm OK 22899086 (Visualise)
22899581 (Visualise)
funai-amazonas-2.osm OK from 27557525 (Visualise)
to 27560240 (Visualise)
funai-amazonas-3.osm OK 27560280 (Visualise)
funai-centro-oeste.osm OK 26958925 (Visualise)
funai-fronteira-co-ve.osm OK 24338448 (Visualise)
24339843 (Visualise)
funai-fronteira-norte.osm OK 22852440 (Visualise)
funai-fronteira-peru.osm OK 22899269 (Visualise)
funai-maranho.osm OK 27561333 (Visualise)
funai-mato-grosso.osm OK 24921833 (Visualise)
funai-nordeste.osm OK 22919257 (Visualise)
funai-pa-mt.osm OK 20820878 (Visualise)
funai-pa-mt-2.osm OK 21770004 (Visualise)
funai-rondonia.osm OK 21392687 (Visualise)
funai-sudeste.osm OK 26958925 (Visualise)
funai-sul.osm OK 24357399 (Visualise)
funai-tocantins.osm OK 24373315 (Visualise)