Skip to content

Instantly share code, notes, and snippets.

View eustomaqua's full-sized avatar

Yijun Bian eustomaqua

View GitHub Profile
@eustomaqua
eustomaqua / Config for CUDA
Last active April 30, 2023 13:32
Configuration on CentOS7 (user setting)
**Windows 10**
```shell
C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.1
(deepl) λ nvcc -V # nvcc --version
(deepl) λ cat version.txt
(deepl) λ cat include\cudnn.h | grep CUDNN_MAJOR -A 2
```
**Cent OS 7**
@eustomaqua
eustomaqua / nvidia_info.md
Last active August 25, 2021 12:50
Tips for Deep Learning #TensorFlow #PyTorch

Windows 10

(deepl) λ nvcc -V
nvcc: NVIDIA (R) Cuda compiler driver
Copyright (c) 2005-2019 NVIDIA Corporation
Built on Sun_Jul_28_19:12:52_Pacific_Daylight_Time_2019
Cuda compilation tools, release 10.1, V10.1.243
C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA
@eustomaqua
eustomaqua / #git commands
Last active May 17, 2021 12:40
Tips of Git Environment #Git #gdb
ubuntu@ubuntu-VirtualBox:/media/sf_GitHubLab/libSGM$ git push
warning: push.default 尚未设置,它的默认值在 Git 2.0 已从 'matching'
变更为 'simple'。若要不再显示本信息并保持传统习惯,进行如下设置:
git config --global push.default matching
若要不再显示本信息并从现在开始采用新的使用习惯,设置:
git config --global push.default simple
@eustomaqua
eustomaqua / import_issue.sh
Last active December 3, 2019 12:09
Tips of Python #Python
(py36env) yjbian@ubri07:~/GitHubLab/ml-fairness-gym$ python spaces/multinomial_test.py
Traceback (most recent call last):
File "spaces/multinomial_test.py", line 24, in <module>
from spaces import multinomial
ImportError: No module named 'spaces'
(py36env) yjbian@ubri07:~/GitHubLab/ml-fairness-gym$ pyth
-sh: pyth: command not found
(py36env) yjbian@ubri07:~/GitHubLab/ml-fairness-gym$ python
Python 3.5.2 (default, Nov 12 2018, 13:43:14)
[GCC 5.4.0 20160609] on linux
@eustomaqua
eustomaqua / .bashrc
Last active December 30, 2019 02:01
Tips of CUDA #GPU
## cuda 9.0: 5-May-2019 central time
export PATH=$HOME/VirtualEnv/cuda90/bin:$PATH
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$HOME/VirtualEnv/cuda90/lib64/
export CPATH=$HOME/VirtualEnv/cuda90/include:$CPATH
export DYLD_LIBRARY_PATH=$HOME/VirtualEnv/cuda90/lib:$DYLD_LIBRARY_PATH
## cuda 10.0: 3-Dec-2019 beijing time
export PATH=/usr/local/cuda/bin:$PATH
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/cuda/lib64/
export CPATH=/usr/local/cuda/include:$CPATH
@eustomaqua
eustomaqua / comments.sh
Last active March 1, 2021 08:03
Tips of Git #Git
# [git 修改 commit 的注释](https://blog.csdn.net/lxf0613050210/article/details/52525083)
# 一、最新的一次提交
git commit --amend
# 最后一次 commit 的修改,但是只能在 push 之前
# 二、历史提交
git rebase -i HEAD~3
# 表示要修改当前版本的倒数第三次状态
@eustomaqua
eustomaqua / multirow.tex
Last active November 22, 2019 12:25
Table Descriptions in Papers #LaTeX
\usepackage{booktabs}
\usepackage{multirow}
% no need of multirow
\begin{table}[t]
\caption{
}\label{}
\centering
\scalebox{0.83}[0.83]{
%\setlength{\tabcolsep}{0.7mm}
@eustomaqua
eustomaqua / subfig.tex
Last active October 4, 2019 07:57
Figure Descriptions in Papers #LaTeX
% journals
\usepackage{graphicx}
\usepackage{subfig}
% \ifCLASSOPTIONcompsoc
% \usepackage[caption=false,font=normalsize,labelfont=sf,textfont=sf]{subfig}
% \else
% \usepackage[caption=false,font=footnotesize]{subfig}
% \fi
@eustomaqua
eustomaqua / algorithm.tex
Last active November 22, 2019 09:17
Tips in Papers #LaTeX
\usepackage{algorithm}
% Use Input/Output in the format of Algorithm
\renewcommand{\algorithmicrequire}{\textbf{Input:}}
\renewcommand{\algorithmicensure}{\textbf{Output:}}
\begin{algorithm}
\caption{Algorithm}
\label{alg}
\begin{algorithmic}[1]
\REQUIRE Inputs