This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Get-ChildItem -path "C:\path\to\my\directory" -recurse -Include *.py | | |
ForEach-Object { | |
(gc $_.FullName) | ? {$_.trim() -ne ""} | Set-Content $_.FullName | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# export all_proxy='socks5://127.0.0.1:1080' | |
# export ALL_PROXY='socks5://127.0.0.1:1080' | |
MUJOCO_PY_MJPRO_PATH="$HOME/.mujoco/mjpro131/bin" | |
export all_proxy='' | |
export ALL_PROXY='' | |
export PATH="$HOME/bin/:$MUJOCO_PY_MJPRO_PATH:/usr/local/cuda/bin:$PATH" | |
export MUJOCO_PATH="$HOME/bin/mjpro140" | |
# export GTEST_DIR="$HOME/lib/googletest/googletest" | |
# export GMOCK_DIR="$HOME/lib/googletest/googlemock" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
" Leader | |
let mapleader = " " | |
set backspace=2 " Backspace deletes like most programs in insert mode | |
set nobackup | |
set nowritebackup | |
set noswapfile " http://robots.thoughtbot.com/post/18739402579/global-gitignore#comment-458413287 | |
set history=50 | |
set ruler " show the cursor position all the time | |
set showcmd " display incomplete commands |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# disable system problem detected | |
sudo sed -i 's/enabled=1/enabled=0/' /etc/default/apport | |
# update and install necessary software | |
## shadowsocks-libev | |
sudo apt-get install software-properties-common -y | |
sudo add-apt-repository ppa:max-c-lv/shadowsocks-libev -y | |
sudo apt-get update |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /usr/bin/env python3 | |
import os | |
import tensorflow as tf | |
import numpy as np | |
import tempfile | |
from tensorflow.python import debug as tfdbg | |
def watch_session(dump_root_dir, train_op, times): | |
''' Dump tensors to temperary directory for analysis''' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Install dependencies | |
sudo apt install libcurl4-openssl-dev iptables-dev autoconf libgmp3-dev libssl-dev pkg-config | |
# Install StrongSwan | |
wget http://download.strongswan.org/strongswan-5.6.1.tar.bz2 | |
tar xjvf strongswan-5.6.1.tar.bz2 && cd strongswan-5.6.1 | |
# FIXME: Some of these options may be redundant, but they work on my laptop. | |
autoconf && ./configure \ | |
--prefix=/usr/local \ |
NewerOlder