echo 'export PATH="${HOME}/.local/bin:$PATH"' >> ~/.bashrc
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
import cProfile | |
import pstats | |
import my_slow_module | |
cProfile.run('my_slow_module.run()', 'restats') | |
p = pstats.Stats('restats') | |
p.sort_stats('cumulative').print_stats(30) |
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/bash | |
## This gist contains step by step instructions to install cuda v9.0 and cudnn 7.2 in ubuntu 18.04 | |
### steps #### | |
# verify the system has a cuda-capable gpu | |
# download and install the nvidia cuda toolkit and cudnn | |
# setup environmental variables | |
# verify the installation | |
### |
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/bash | |
# Don't actually run this file as a script, just follow directions in the pdf which doesn't copy/paste | |
# https://www.intel.com/content/www/us/en/support/articles/000028171/emerging-technologies/intel-realsense-technology.html | |
# Copy/paste instructions https://github.com/IntelRealSense/librealsense/issues/2884#issuecomment-448049644 | |
echo 'deb http://realsense-hw-public.s3.amazonaws.com/Debian/apt-repo xenial main'| sudo tee /etc/apt/sources.list.d/realsense-public.list | |
sudo apt-key adv--keyserverkeys.gnupg.net --recv-key 6F3EFCDE | |
sudo apt-get update |
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 | |
ORIGINAL_PATH=$PATH | |
export PATH=/usr/local/cuda-9.0/bin:$PATH | |
ORIGINAL_LD_LIBRARY_PATH=$LD_LIBRARY_PATH | |
export LD_LIBRARY_PATH=/usr/local/cuda-9.0/lib64:/usr/local/cuda-9.0/extras/CUPTI/lib64:/lib/nccl/cuda-9:$LD_LIBRARY_PATH |
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 | |
export PATH=$ORIGINAL_PATH | |
unset ORIGINAL_PATH | |
export LD_LIBRARY_PATH=$ORIGINAL_LD_LIBRARY_PATH | |
unset ORIGINAL_LD_LIBRARY_PATH |
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/bash | |
# https://gist.github.com/robwierzbowski/5430952/ | |
# Create and push to a new github repo from the command line. | |
# Grabs sensible defaults from the containing folder and `.gitconfig`. | |
# Refinements welcome. | |
# Gather constant vars | |
CURRENTDIR=${PWD##*/} | |
GITHUBUSER=$(git config github.user) |
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/bash | |
git_create () { | |
# Based on https://gist.github.com/robwierzbowski/5430952/ | |
# Get defaults | |
CURRENTDIR=${PWD##*/} | |
GITHUBUSER=$(git config github.user) |
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
FROM osrf/ros:melodic-desktop-bionic | |
# setup catkin workspace | |
ENV CATKIN_WS=/root/catkin_ws | |
RUN mkdir -p $CATKIN_WS/src | |
WORKDIR $CATKIN_WS/src | |
# clone source code | |
RUN git clone -b melodic-devel https://github.com/ros-visualization/rviz |
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
data: text/html, | |
<html> | |
<head> | |
<title>Notepad</title> | |
<link rel="icon" type="image/png" href="http://icons.iconarchive.com/icons/hopstarter/sleek-xp-software/256/Notepad-icon.png"> | |
<script src="http://code.jquery.com/jquery-2.0.3.min.js"></script> | |
<script type="text/javascript"> | |
$(document).ready(function() { | |
$('#text').bind('keyup', function() { | |
var content = $(this).val(); |