##TUNING##
System: set file descriptors to 32K or 64K
vim /etc/security/limit.conf
#!/bin/sh | |
# installation of Oracle Java JDK. | |
sudo apt-get -y update | |
sudo apt-get -y install python-software-properties | |
sudo add-apt-repository -y ppa:webupd8team/java | |
sudo apt-get -y update | |
sudo apt-get -y install oracle-java7-installer | |
# Installation of commonly used python scipy tools |
def plot_correlogram(df,figsize=(20,20)): | |
''' Creat an n x n matrix of scatter plots for every | |
combination of numeric columns in a dataframe''' | |
cols = list(df.columns[df.dtypes=='float64']) | |
n = len(cols) | |
fig, ax = plt.subplots(n,n,figsize=figsize) | |
for i,y in enumerate(cols): | |
for j,x in enumerate(cols): | |
if i != n-1: |
import json | |
import os | |
import time | |
import requests | |
from PIL import Image | |
from StringIO import StringIO | |
from requests.exceptions import ConnectionError | |
def go(query, path): | |
"""Download full size images from Google image search. |
"""Tools for searching Pubmed for a list of PMIDs. | |
The goal here is to search for many PMIDs at once, since searching | |
sequentially can take a long time. Using the the BioPython Entrez module | |
is super convenient to this end. | |
The results results are returned in a simple dictionary format. | |
""" | |
First of all, it just seems like doing anything with Oracle is obnoxiously painful for no good reason. It's the nature of the beast I suppose. cx_oracle is a python module that allows you to connect to an Oracle Database and issue queries, inserts, updates..usual jazz.
Step 1:
sudo apt-get install build-essential unzip python-dev libaio-dev
Step 2. Click here to download the appropriate zip files required for this. You'll need:
# My steps for creating a DigitalOcean server to run non-exit Tor node for just $5/mo | |
# Screen shots of my setup process: https://plus.google.com/photos/+DrewFustini/albums/6057260188204970945 | |
# Create Digital Ocean account: https://www.digitalocean.com/ | |
# Create Droplet on Digital Ocean: select $5/mo, and select Debian 7.0 64-bit | |
# This instructions are based on Tor Project: https://www.torproject.org/docs/tor-relay-debian.html.en | |
afustini@lappy486:~$ ssh [email protected] | |
[email protected]'s password: | |
You are required to change your password immediately (root enforced) | |
Linux Tor300SoF 3.2.0-4-amd64 #1 SMP Debian 3.2.54-2 x86_64 |
""" | |
modified for Python 2.7 and unicode | |
get your goup id at https://lookup-id.com/ | |
get your acess token at https://developers.facebook.com/tools/explorer/ | |
fork from | |
fbfeed2csv: a tool to download all posts from a user/group/page's facebook feed to a csv file | |
yuzawa-san | |
https://github.com/yuzawa-san | |
""" |