Skip to content

Instantly share code, notes, and snippets.

View Bl3f's full-sized avatar
🙃
Doing stuff

Christophe Blefari Bl3f

🙃
Doing stuff
View GitHub Profile
@Bl3f
Bl3f / gist:f5587d45c94a8f3ade66ba30086bc65f
Created May 20, 2022 11:06
50 most common words in the Data News
[('data', 1192),
('week', 187),
('post', 171),
('new', 163),
('also', 162),
('airflow', 160),
('like', 141),
('dbt', 140),
('team', 136),
('credits', 135),
@Bl3f
Bl3f / paris.json
Last active August 21, 2019 14:09
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
{
"fields": [
{"name": "tpep_pickup_datetime", "format": "YYYY-M-D H:m:s", "type": "timestamp"},
{"name": "pickup_longitude", "format": "", "type": "real"},
{"name": "pickup_latitude", "format": "", "type": "real"}
],
"rows": [
["2015-01-15 19:05:39 +00:00", -73.99389648, 40.75011063],
["2015-01-15 19:05:39 +00:00", -73.97642517, 40.73981094],
["2015-01-15 19:05:40 +00:00", -73.96870422, 40.75424576]
@Bl3f
Bl3f / conftest.py
Last active October 19, 2018 13:41
Airflow unit testing DAG (topological order)
import pytest
from airflow.hooks.base_hook import BaseHook
from airflow.models import Connection
def create_connection(conn_id, schema=None, *args, **kwargs):
if schema is None:
schema = conn_id
return Connection(conn_id=conn_id, schema=schema, *args, **kwargs)
@Bl3f
Bl3f / .block
Last active February 19, 2022 12:27
Simple D3.js heatmap
license: WTFPL
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@Bl3f
Bl3f / searchmetrics_api.py
Created April 14, 2015 09:51
Python wrapper for SearchMetrics API v1. Need Oauth.
import datetime
import itertools
import oauth2 as oauth
import requests
import time
class SearchMetricAPIError(Exception):
pass