Skip to content

Instantly share code, notes, and snippets.

View elijah-tai's full-sized avatar
🌭
What’s happening?

Elijah Tai elijah-tai

🌭
What’s happening?
View GitHub Profile
@elijah-tai
elijah-tai / eth_mining_setup.sh
Created May 30, 2020 22:55
Setup script for mining ETH on Ubuntu (last used 2017)
# prereqs
sudo apt-get -y update
sudo apt-get -y upgrade
sudo apt-get -y install build-essential
sudo apt-get -y install sudo wget vim screen git software-properties-common
# nvidia cuda drivers
cd /media
sudo wget http://developer.download.nvidia.com/compute/cuda/repos/ubuntu1404/x86_64/cuda-repo-ubuntu1404_8.0.44-1_amd64.deb
sudo dpkg -i cuda-repo-ubuntu1404_8.0.44-1_amd64.deb
@elijah-tai
elijah-tai / useHexo.md
Created November 23, 2017 19:43 — forked from btfak/useHexo.md
How to use Hexo and deploy to GitHub Pages

Keybase proof

I hereby claim:

  • I am itselijahtai on github.
  • I am elijahtai (https://keybase.io/elijahtai) on keybase.
  • I have a public key whose fingerprint is E376 F132 8F9C 70CF 683B 85B9 811A 3608 C365 C323

To claim this, I am signing this object:

#List unique values in a DataFrame column
pd.unique(df.column_name.ravel())
#Convert Series datatype to numeric, getting rid of any non-numeric values
df['col'] = df['col'].astype(str).convert_objects(convert_numeric=True)
#Grab DataFrame rows where column has certain values
valuelist = ['value1', 'value2', 'value3']
df = df[df.column.isin(value_list)]
@elijah-tai
elijah-tai / Spark+ipython_on_MacOS.md
Created May 30, 2016 14:41 — forked from ololobus/Spark+ipython_on_MacOS.md
Apache Spark installation + ipython notebook integration guide for Mac OS X

Apache Spark installation + ipython notebook integration guide for Mac OS X

Tested with Apache Spark 1.3.1, Python 2.7.9 and Java 1.8.0_45 + workaround for Spark 1.4.x from @enahwe.

Install Java Development Kit

Download and install it from oracle.com