Skip to content

Instantly share code, notes, and snippets.

View jigangkim's full-sized avatar
🎯
Focusing

Jigang Kim jigangkim

🎯
Focusing
View GitHub Profile
@jigangkim
jigangkim / settings.json
Created May 18, 2020 02:06
vscode global settings (in /home/<your user name>/.config/Code/User)
{
"remote.SSH.showLoginTerminal": true,
"extensions.autoUpdate": false,
"git.confirmSync": false,
"gitlens.defaultDateStyle": "absolute",
"window.restoreWindows": "none",
"window.zoomLevel": 0,
"timeline.pageSize": 0,
"remote.extensionKind": {
"shyykoserhiy.vscode-spotify": "ui"
@jigangkim
jigangkim / README.md
Last active July 7, 2021 11:30
Jupyter notebook as a service on Ubuntu 18.04
  1. Install jupyter
conda activate base
which pip
pip install notebook==6.0.3
jupyter-notebook --generate-config
  1. Configure jupyter
@jigangkim
jigangkim / .griveignore
Created July 15, 2020 06:47 — forked from jgkim2020/.griveignore
regex based ignore for grive2 (https://github.com/vitalif/grive2)
# Ignore everything under "some_folder" folder...
some_folder/**
# ...except "some_file.txt"
!some_folder/some_file.txt
@jigangkim
jigangkim / 10-quirks.conf
Created July 15, 2020 06:47 — forked from jgkim2020/10-quirks.conf
Fix for MSI laptop random screen brightness bug (/usr/share/X11/xorg.conf.d/10-quirks.conf)
# MSI laptop random screen brightness bug
# https://askubuntu.com/questions/777754/brightness-randomly-up-and-down-on-msi-laptop/808785#808785
Section "InputClass"
Identifier "Spooky Ghosts"
MatchProduct "Video Bus"
Option "Ignore" "on"
EndSection
@jigangkim
jigangkim / conda_env_export.sh
Created July 15, 2020 06:47 — forked from jgkim2020/conda_env_export.sh
How to export conda environment
conda env export > env.yml --no-builds # do not specify build (--no-builds) for cross-platform compatibility
conda env create --name exported-env -f env.yml
conda env remove --name exported-emv
@jigangkim
jigangkim / xvfb_commands.md
Created March 19, 2021 02:07
xvfb commands

Commands

$ xdpyinfo -display :95 >/dev/null 2>&1 && echo "In use" || echo "Free"

$ Xvfb :95 -screen 0 1400x900x24 & DISPLAY=:95 [ [...]]

@jigangkim
jigangkim / bash_vpnshift.sh
Last active April 26, 2022 07:12
vpnshift application commands /scripts
usage="usage: bash bash_vpnshift.sh -n <netns>"
quick_die() {
format="$1"; shift
>&2 printf "${format}\n" "$@"
exit 1
}
main() {
while getopts "hn:" opt; do
@jigangkim
jigangkim / .bash_aliases
Last active April 29, 2023 02:46
Auto setup for GIT_ASKPASS with support for encrypted tokens (https://jigang.kim/blog/replace-github-token-with-password/)
alias gitoken='source ~/autosetup/github-setup.sh'
@jigangkim
jigangkim / rosmessages.py
Created May 11, 2021 10:45
ROS messages
# Subscribe from multisim node
measurement_sub = rospy.Subscriber('crazyflie'+str(i_agent)+'/measurement',PointStamped,self.measurement_cb,i_agent) # measurement for GP
env_target_sub = rospy.Subscriber('env/target_locations',Float32MultiArray,self.env_target_cb) # target position
env_obstacle_sub = rospy.Subscriber('env/obstacle_locations',Float32MultiArray,self.env_obstacle_cb) # obstacle position
position_sub = [[rospy.Subscriber('crazyflie'+str(i)+'/kalman/position',PointStamped, self.position_cb,i)] for i in range(num_agents)] # agent position
# Publish to multisim node(?)
self.position_sp_pub = [[rospy.Publisher('crazyflie'+str(i)+'/cmd_position', TwistStamped, queue_size=10)] for i in range(num_agents)] # desired position
# Service from gcs
@jigangkim
jigangkim / popos2004_initialsetup.sh
Created July 9, 2021 01:51
Pop OS quick setup script
# Misc
sudo apt update
sudo apt install guake
sudo apt install openssh-server
#sudo apt install patchelf
#sudo apt-get install -y python3-dev libasound2-dev
# NVIDIA CUDA & CUDNN
sudo apt install system76-cudnn-11.2
sudo update-alternatives --config cuda