In this article, I will share some of my experience on installing NVIDIA driver and CUDA on Linux OS. Here I mainly use Ubuntu as example. Comments for CentOS/Fedora are also provided as much as I can.
This file contains hidden or 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
############################################################################### | |
# Compiling the RPi kernel in situ, with optional memory leak debugging | |
# | |
# Extends https://www.raspberrypi.org/documentation/linux/kernel/building.md | |
############################################################################### | |
# On the Raspberry Pi | |
cd ~/Projects | |
# Install rerequisites |
This file contains hidden or 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
# npm using https for git | |
git config --global url."https://github.com/".insteadOf [email protected]: | |
git config --global url."https://".insteadOf git:// | |
# npm using git for https | |
git config --global url."[email protected]:".insteadOf https://github.com/ | |
git config --global url."git://".insteadOf https:// |
This file contains hidden or 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
URxvt.saveLines: 2000 | |
URxvt.scrollBar: false | |
URxvt.foreground: #f9f7f1 | |
URxvt.depth: 32 | |
URxvt.secondaryScroll: true | |
URxvt.font: xft:DejaVu Sans Mono for Powerline:pixelsize=22:antialias=true | |
URxvt.perl-ext-common: default,matcher,selection-to-clipboard | |
URxvt.urlLauncher: chromium | |
URxvt.matcher.button: 1 | |
URxvt.tabbed.saveLines: 2000 |
This file contains hidden or 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 QEMU OSX port with ARM support | |
sudo port install qemu +target_arm | |
export QEMU=$(which qemu-system-arm) | |
# Dowload kernel and export location | |
curl -OL \ | |
https://github.com/dhruvvyas90/qemu-rpi-kernel/blob/master/kernel-qemu-4.1.7-jessie | |
export RPI_KERNEL=./kernel-qemu-4.1.7-jessie | |
# Download filesystem and export location |
This file contains hidden or 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
""" | |
A simple FiveThirtyEight palette for Seaborn plots. | |
""" | |
import seaborn as sns | |
import matplotlib.pyplot as plt | |
five_thirty_eight = [ | |
"#30a2da", | |
"#fc4f30", |
This file contains hidden or 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
#!/bin/csh | |
# Get the name of this script | |
if ( $?_ ) then | |
# With tcsh the name of the file being sourced is available in | |
# $_. | |
set script_name = `basename $_` | |
else | |
# Fall back to $0 which, sometimes, will be the name of the |
This file contains hidden or 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
#!/bin/sh | |
allpdfs="" | |
for f in "$@" ; do | |
filename=$(basename "$f") | |
filename="${filename%.*}" | |
pygmentize -f tex -O linenos -O title=$( echo $filename | tr '_' '-').py -O full -O style=default -o /tmp/$filename.tex $f | |
pdflatex -jobname=$filename -output-directory=/tmp /tmp/$filename.tex | |
allpdfs="$allpdfs /tmp/$filename.pdf" |
This file contains hidden or 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
############################################################################################## | |
##Running fsl from the command line | |
##some commands that I find useful | |
## | |
############################################################################################## | |
############################################################################################## | |
############################################################################################## | |
##Using the fslmaths and fslstats toolboxes | |
############################################################################################## |
rsync (Everyone seems to like -z, but it is much slower for me)
- a: archive mode - rescursive, preserves owner, preserves permissions, preserves modification times, preserves group, copies symlinks as symlinks, preserves device files.
- H: preserves hard-links
- A: preserves ACLs