Skip to content

Instantly share code, notes, and snippets.

Francesco Bruni brunifrancesco

View GitHub Profile
brunifrancesco /
Created Apr 16, 2019
Ingest and visualize landsat data
import rasterio
import geopyspark as gps
import numpy as np
import matplotlib
import as cm
from pyspark import SparkContext
conf = gps.geopyspark_conf(master="local[*]", appName="ingest-example", )
conf.set(key='spark.kryoserializer.buffer.max', value='256m')
# -*- coding: utf-8 -*-
Get Paris attractions data scraping the BASE_URL site.
Wrap those data into a json structure.
- BeautifulSoup
- requests
- fn
brunifrancesco /
Created Jan 12, 2016
Process and parse HTML files to get them complied with the Angular "translate" filter. The scripts create also the final json file which will contain all the needed translations.
#! /usr/bin/env python
Process some HTML files to add translation features.
The script replaces simple strings (avoiding parsing special chars, comments, Angular based variables, HTML entities)
and any other Angular related stuff with the same string followed by the 'translate' filter as stated in .
To be translated labels got memorized in the final json file, where translations values will be present.
File by file, processed content is stored in a new file letting the original one intact.
Install required deps
You can’t perform that action at this time.