Skip to content

Instantly share code, notes, and snippets.

import geopandas as gp
import pandas as pd
from owslib.wms import WebMapService
import owslib.util as util
import matplotlib.pyplot as plt
from shapely.geometry import box
import os
wms = WebMapService('https://maps.cscrs.itu.edu.tr/geoserver/ows?service=WMS',
username='****',password='****', version='1.3.0')
import geopandas as gp
from owslib.wms import WebMapService
import owslib.util as util
import matplotlib.pyplot as plt
collapsed = gp.read_file('bina_kirmizi_utm37.shp')
collapsed['centroid'] = collapsed.centroid
collapsed['centroid'] = collapsed['centroid'].to_crs(crs=4326)
collapsed = collapsed.to_crs(crs=4326)
from qgis.core import QgsProject
# modelin istedigi boyut bu
# poligon bir sekilde bundan buyuk veya kucuk olursa
# stretch/shrink etmek gerekecek.
width, height, nchannels = (224, 244, 3)
project = QgsProject.instance()
# Post-earthquake raster katmani
post_eq_rlayer = project.mapLayersByName('Hatay_PHR1B_20230208_3')[0]
print(post_eq_rlayer)
aws s3 cp --no-sign-request s3://maxar-opendata/events/Kahramanmaras-turkey-earthquake-23/ard/37/031133010302/2023-02-07/1040010082698700-visual.tif .
aws s3 cp --no-sign-request s3://maxar-opendata/events/Kahramanmaras-turkey-earthquake-23/ard/37/031133010333/2023-02-07/1040010082698700-visual.tif .
aws s3 cp --no-sign-request s3://maxar-opendata/events/Kahramanmaras-turkey-earthquake-23/ard/37/031133010333/2023-02-07/1050050044DE7E00-visual.tif .
aws s3 cp --no-sign-request s3://maxar-opendata/events/Kahramanmaras-turkey-earthquake-23/ard/37/031133010332/2023-02-07/1040010082698700-visual.tif .
aws s3 cp --no-sign-request s3://maxar-opendata/events/Kahramanmaras-turkey-earthquake-23/ard/37/031133010332/2023-02-07/1050050044DE7E00-visual.tif .
aws s3 cp --no-sign-request s3://maxar-opendata/events/Kahramanmaras-turkey-earthquake-23/ard/37/031133012001/2023-02-07/1050050044DE7F00-visual.tif .
aws s3 cp --no-sign-request s3://maxar-opendata/events/Kahramanmaras-turkey-earthquake-23/ard/37/031133010303/2023-02-
@hkayabilisim
hkayabilisim / sinePlot.m
Created October 8, 2012 07:37
Plotting a sine function.
t = linspace(0,2*pi,100);
plot(t,sin(t));