- open new tab:
Cmd + t
- next tab:
Cmd + Shift + ]
- previous tab:
Cmd + Shift + [
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Layer from Memory | |
layer = QgsVectorLayer('Point?crs=epsg:4326', 'MyPoint' ,'memory') | |
pr = layer.dataProvider() | |
pt = QgsFeature() | |
point1 = QgsPoint(-35.92,-7.24) | |
pt.setGeometry(QgsGeometry.fromPoint(point1)) | |
pr.addFeatures([pt]) | |
layer.updateExtents() | |
QgsMapLayerRegistry.instance().addMapLayers([layer]) |
baseado no meu outro tutorial https://gist.github.com/luzfcb/1a7f64adf5d12c2d357d0b4319fe9dcd que é mais atualizado que este. Eu não constumo atualizar esse tutorial, mas é bom para dar uma visão geral simplista das configurações.
Use o pyenv https://github.com/pyenv/pyenv para baixar, instalar e gerenciar múltiplas versões do INTERPRETADOR Python na sua maquina.
Primeiro instale as dependências:
Linux (Ubuntu):
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Shell script to create a complete Django project. | |
# This script require Python 3.x and pyenv | |
# Settings.py is config to Django 1.9.3 | |
# The project contains: | |
# Settings config | |
# Person model and form | |
# Person list and detail | |
# Person create, update and delete | |
# Admin config |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Shell script to create a complete Django project. | |
# This script require Python 3.x and pyenv | |
# Settings.py is config to Django 2.2.12 | |
# The project contains: | |
# Settings config | |
# Person model and form | |
# Person list and detail | |
# Person create, update and delete | |
# Admin config |
This is a collection of information on PostgreSQL and PostGIS for what I tend to use most often.
#Mac OS X
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- Abordagem tradicional (vetor/vetor): | |
SELECT foo.value, ST_area(foo.geom::geography)/10000 AS area_ha | |
FROM ( SELECT c.value, | |
ST_Union(ST_Intersection(f.geom, c.geom)) as geom | |
FROM fazendas f, capacidade_vect c | |
WHERE ST_Intersects(f.geom, c.geom) | |
AND f.gid = 6 | |
GROUP BY c.value | |
) as foo | |
ORDER BY foo.value; |
NewerOlder