Skip to content

Instantly share code, notes, and snippets.

View nateGeorge's full-sized avatar

Nate George nateGeorge

View GitHub Profile
@mbostock
mbostock / .block
Last active February 9, 2016 02:04
Rotating Orthographic
license: gpl-3.0
#define SSID "wi-fi_login" // ваш SSID
#define PASS "wi-fi_password" // ваш пароль Wi-Fi
#define SMTPServer "s02.atomsmtp.com" //smtp сервер
#define SMTPPort "2525" // smtp порт
#define MailLogin "smtp_example@gmail.com" // логин для smtp
#define MailLoginBase64 "dWd1LCBrb25lNG5vCg==" //логин для smtp в Base64
#define MailPasswordBase64 "aHJlbiB0YW0K" // пароль для smtp в Base64
#define MailRelay "example@mail.ru" // промежуточная почта для "отмывания" email
#define PhoneNumber "375290000000" // номер телефона
@junjiah
junjiah / bellman_ford.py
Created August 30, 2015 14:03
solved 'Breadth First Search: Shortest Reach' on hackerrank https://www.hackerrank.com/challenges/bfsshortreach
from collections import namedtuple
# A reasonable large number to represent infinity.
INF = (1 << 31)
UNIT_LENGTH = 6
# Struct for edges.
Edge = namedtuple('Edge', ['src', 'dest'])
def calculate_shortest_distances(node_num, edges, src):
@mikeboers
mikeboers / epic.py
Created July 22, 2016 16:58
Downloader for NASA's DSCOVR EPIC images
import argparse
import datetime
import json
import os
import re
import requests
parser = argparse.ArgumentParser()
@jimoconnell
jimoconnell / init.lua
Last active February 12, 2017 21:05
Code by HoracioBouzas, formatted for use with ESPlorer
--http://www.instructables.com/id/ESP8266-based-web-configurable-wifi-general-purpos-1/
--Code by HoracioBouzas, formatted for use with ESPlorer by jimoconnell
print("WIFI control");
-- put module in AP mode
wifi.setmode(wifi.SOFTAP);
print("ESP8266 mode is: " .. wifi.getmode());
cfg={};
-- Set the SSID of the module in AP mode and access password
cfg.ssid="ESP8266";
cfg.pwd="passwordpassword";
@pprett
pprett / grid_search.py
Created October 31, 2012 19:42
Parallel grid search for sklearn Gradient Boosting
"""Parallel grid search for sklearn's GradientBoosting.
This script uses IPython.parallel to run cross-validated
grid search on an IPython cluster. Each cell on the parameter grid
will be evaluated ``K`` times - results are stored in MongoDB.
The procedure tunes the number of trees ``n_estimators`` by averaging
the staged scores of the GBRT model averaged over all K folds.
You need an IPython ipcluster to connect to - for local use simply
@lukedeo
lukedeo / savekeras.py
Created December 20, 2015 00:28
Saving a Keras model.
'''
hacked out deepdish.io style keras NN saving functionality
[credit] deepdish
'''
from __future__ import division, print_function, absolute_import
import numpy as np
import tables
import warnings
@nachiket-p
nachiket-p / meteor_servercall.html
Created June 21, 2012 07:41
Meteor: Calling server method from client
<head>
<title>meteor_servercall</title>
</head>
<body>
{{> simple}}
{{> passData}}
</body>
<template name="simple">
@rcdilorenzo
rcdilorenzo / worldclass-save-discussions.js
Created March 16, 2019 18:34
A puppeteer script to download all discussions for a given WorldClass topic (assumes WORLDCLASS_DOMAIN environment is set)
const puppeteer = require('puppeteer');
const read = require('read');
const htmlToText = require('html-to-text').fromString;
const R = require('ramda');
const Promise = require('bluebird');
const fs = require('fs');
const download = require('@jinphen/download2');
const { CookieJar } = require('tough-cookie');
const mapSeries = R.flip(Promise.mapSeries);
@abalter
abalter / ...README.md
Created January 8, 2019 21:56
A function to enable using conda seamlessly with R
  • Install EVERYTHING you can with conda
  • Install things you can with:
    • install.packages(, lib="")
    • install.github(, lib="")
    • biocLite(, lib="")
  • Make separate local libs for different R versions
  • After installing a package to a local lib, look there and see if there are dependencies you could have installed with conda.
  • Or, head it off by looking at the dependencies in CRAN or Bioconductor