start new:
tmux
start new with session name:
tmux new -s myname
#!/bin/bash | |
# Script for installing tmux on systems where you don't have root access. | |
# tmux will be installed in $HOME/local/bin. | |
# It's assumed that wget and a C/C++ compiler are installed. | |
# exit on error | |
set -e | |
TMUX_VERSION=1.8 |
import itertools | |
import numpy as np | |
from sklearn.linear_model import SGDClassifier, SGDRanking | |
from sklearn import metrics | |
from minirank.compat import RankSVM as MinirankSVM | |
from scipy import stats | |
"""making a dataframe""" | |
df = pd.DataFrame([[1, 2], [3, 4]], columns=list('AB')) | |
"""quick way to create an interesting data frame to try things out""" | |
df = pd.DataFrame(np.random.randn(5, 4), columns=['a', 'b', 'c', 'd']) | |
"""convert a dictionary into a DataFrame""" | |
"""make the keys into columns""" | |
df = pd.DataFrame(dic, index=[0]) |
# Make mouse useful in copy mode | |
setw -g mode-mouse on | |
# Allow mouse to select which pane to use | |
set -g mouse-select-pane on | |
# Allow mouse dragging to resize panes | |
set -g mouse-resize-pane on | |
# Allow mouse to select windows |
typealias HANDLE Ptr{Void} | |
typealias DWORD Uint32 | |
typealias WORD Uint16 | |
typealias LPTSTR Cwchar_t | |
typealias LPBYTE Ptr{Char} | |
immutable STARTUPINFO | |
cb::DWORD | |
lpReserved::LPTSTR | |
lpDesktop::LPTSTR |
"""Download Dash User Docsets and install them in Zeal""" | |
import configparser | |
import json | |
import tarfile | |
import urllib.request | |
from pathlib import Path | |
from sys import platform | |
import easygui |
#!/usr/bin/env python | |
# License: MIT Open Source | |
# Copyright (c) 2016 Joe Linoff | |
''' | |
The tool runs ssh or scp as a child process with a connected psuedo | |
terminal (pty). | |
It will automatically answer yes to the "Are you sure you want to | |
continue connecting (yes/no)?" if it comes up. |
from keras.models import Sequential | |
from keras.layers import Dense | |
from keras.utils.io_utils import HDF5Matrix | |
import numpy as np | |
def create_dataset(): | |
import h5py | |
X = np.random.randn(200,10).astype('float32') | |
y = np.random.randint(0, 2, size=(200,1)) | |
f = h5py.File('test.h5', 'w') |