Skip to content

Instantly share code, notes, and snippets.

View tillahoffmann's full-sized avatar

Till Hoffmann tillahoffmann

View GitHub Profile
@tillahoffmann
tillahoffmann / readleaf.user.js
Last active October 6, 2023 21:30
Readcube-Overleaf integration: Adds an "Update Library" button to Overleaf that allows you to import your Readcube library.
// ==UserScript==
// @name Readcube-Overleaf integration
// @namespace https://tillahoffmann.github.io/
// @version 0.1
// @description Adds an "Update Library" button to Overleaf that allows you to import your Readcube library.
// @author Till Hoffmann
// @match https://www.overleaf.com/*
// @connect readcube.com
// @grant GM_xmlhttpRequest
// ==/UserScript==
@tillahoffmann
tillahoffmann / weighted_kde.ipynb
Last active June 24, 2023 07:39
Weighted kernel density estimation based on `scipy.stats.gaussian_kde`.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

Data accompanying the publication "Wastewater Catchment Areas in Great Britain"

Code to reproduce the results can be found in the accompanying repository. The resultant data comprise

  • catchments_consolidated.*: geospatial data as a shapefile in the British National Grid projection, including auxiliary files. Each feature has the following attributes:

    • identifier: a unique identifier for the catchment based on its geometry. These identifiers are stable across different versions of the data provided the geometry of the associated catchment remains unchanged.
    • company: the water company that contributed the feature.
    • name: the name of the catchment as provided by the water company.
  • comment (optional): an annotation providing additional information about the catchment, e.g. overlaps with other catchments.

We can't make this file beautiful and searchable because it's too large.
"theta","rho","C1","C2","C3","C4","C5","C6","C7"
5.16004198230803,0.240250562783331,29,22.6429951726459,4.50612244897959,6.09779033565804,15,11,6
1.78052346222103,3.58324605505913,11,4.06614730600268,1.19183673469388,11.7077033880623,6,37,2
8.18850920768455,5.21797996014357,27,22.3963479569647,4.20163265306122,5.02584656458809,22,9,12
1.94151380797848,5.9612188488245,6,5.39146609371528,0.860408163265306,0.115489458194625,6,37,2
1.81142480578274,0.973127665929496,6,3.10169262229465,0.782857142857143,0.0434027777777778,7,32,2
5.12457573786378,0.697821727953851,37,0.066773867001757,12.2685714285714,5.22543680195018,12,10,3
3.33208687137812,6.31788031198084,19,6.08835836756043,4.80081632653061,3.92653515713548,16,11,8
3.18306566914544,6.59299547318369,25,15.7205617986619,7.13469387755102,9.61977683572063,13,15,5
9.81655519222841,3.44068030361086,65,15.0540117465425,8.86367346938776,5.81210758413745,29,6,18
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
[
{
"number": 6222258175386405304,
"cid": "uEmt9NfmWVYJ"
},
{
"number": 15091031681562760571,
"cid": "e9W20VsdbtEJ"
},
{
@tillahoffmann
tillahoffmann / cython_line_profiler.ipynb
Created February 3, 2015 14:48
Demonstration of line-by-line profiling for `cython` functions.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.