Skip to content

Instantly share code, notes, and snippets.

@fo40225
fo40225 / 8xP1-1tb.log
Created April 15, 2019 14:10
8x Micron Crucial P1 1TB mdadm raid0 test
8x P1 1TB
SeqQ32T1read: (groupid=0, jobs=1): err= 0: pid=2451: Mon Apr 15 22:05:42 2019
read: IOPS=10.1k, BW=1267MiB/s (1329MB/s)(5120MiB/4041msec)
clat (usec): min=60, max=1629, avg=97.97, stdev=54.12
lat (usec): min=60, max=1629, avg=98.05, stdev=54.12
clat percentiles (usec):
| 1.00th=[ 62], 5.00th=[ 62], 10.00th=[ 63], 20.00th=[ 64],
| 30.00th=[ 66], 40.00th=[ 71], 50.00th=[ 82], 60.00th=[ 94],
| 70.00th=[ 109], 80.00th=[ 121], 90.00th=[ 145], 95.00th=[ 239],
| 99.00th=[ 253], 99.50th=[ 265], 99.90th=[ 570], 99.95th=[ 701],
@fo40225
fo40225 / samtools.sh
Last active June 13, 2019 06:42
htslib, samtools, bcftools
sudo apt update
sudo apt install -y build-essential autoconf zlib1g-dev libbz2-dev liblzma-dev libncurses5-dev libperl-dev libgsl-dev
git clone https://github.com/samtools/htslib.git -b 1.9
cd htslib
autoheader
autoconf
./configure
make -j $(nproc)
sudo make install
@fo40225
fo40225 / ubuntu_network_setting.txt
Last active May 10, 2020 20:08
ubuntu network setting
# ubuntu server 16.04
/etc/network/interfaces
# dhcp
---
auto eth0
iface eth0 inet dhcp
---
# static
@fo40225
fo40225 / ifcfg
Created April 2, 2019 08:52
CentOS 6.10 network setting
/etc/sysconfig/network-scripts/ifcfg-eth0
ONBOOT=yes
BOOTPROTO=static
IPADDR=192.168.1.2
NETMASK=255.255.255.0
GATEWAY=192.168.1.1
DNS1=192.168.1.1
DNS2=192.168.1.1
@fo40225
fo40225 / script.py
Last active March 23, 2020 12:04
twgc windows keras tensorflow misc
# 國網專用
import os
os.environ["HDF5_USE_FILE_LOCKING"] = "FALSE"
import os
import multiprocessing
import psutil
IO_THREADS=multiprocessing.cpu_count()
CPU_THREADS=psutil.cpu_count(logical=False)
@fo40225
fo40225 / tf_var.txt
Last active October 3, 2024 12:59
some environment variables of tensorflow
# 1.12.0 prevent VRAM occupied
export TF_FORCE_GPU_ALLOW_GROWTH="true"
# <1.12
from keras import backend as K
import tensorflow as tf
config = tf.ConfigProto()
config.gpu_options.allow_growth = True
session = tf.Session(config=config)
@fo40225
fo40225 / docker.sh
Last active June 21, 2019 03:20
install docker and nvidia docker
# Older versions of Docker were called docker, docker.io , or docker-engine. If these are installed, uninstall them
sudo apt-get remove docker docker-engine docker.io containerd runc
# SET UP THE REPOSITORY
sudo apt-get update
sudo apt-get install -y \
apt-transport-https \
ca-certificates \
curl \
gnupg-agent \
@fo40225
fo40225 / 1604.txt
Created March 31, 2019 09:33
ubuntu 16.04 apt list
Listing...
accountsservice/now 0.6.40-2ubuntu10 amd64 [installed,local]
acl/now 2.2.52-3 amd64 [installed,local]
acpid/now 1:2.0.26-1ubuntu2 amd64 [installed,local]
adduser/now 3.113+nmu3ubuntu4 all [installed,local]
apparmor/now 2.10.95-0ubuntu2 amd64 [installed,local]
apport/now 2.20.1-0ubuntu2 all [installed,local]
apport-symptoms/now 0.20 all [installed,local]
apt/now 1.2.10ubuntu1 amd64 [installed,local]
apt-transport-https/now 1.2.10ubuntu1 amd64 [installed,local]
@fo40225
fo40225 / 1804.txt
Created March 31, 2019 09:03
ubuntu 18.04 apt list
Listing...
accountsservice/now 0.6.45-1ubuntu1 amd64 [installed,local]
acl/now 2.2.52-3build1 amd64 [installed,local]
acpid/now 1:2.0.28-1ubuntu1 amd64 [installed,local]
adduser/now 3.116ubuntu1 all [installed,local]
apparmor/now 2.12-4ubuntu5 amd64 [installed,local]
apport/now 2.20.9-0ubuntu7 all [installed,local]
apport-symptoms/now 0.20 all [installed,local]
apt/now 1.6.1 amd64 [installed,local]
apt-utils/now 1.6.1 amd64 [installed,local]
@fo40225
fo40225 / deepvariant.sh
Last active April 27, 2019 04:38
run deepvariant
sudo apt install -y libcurl4
pip install intervaltree==2.1.0 tensorflow
wget https://github.com/google/deepvariant/releases/download/v0.7.2/deepvariant.zip
unzip deepvariant.zip
python make_examples.zip \
--mode calling \
--ref "ref.fa" \
--reads "marked_duplicates.bam" \
--examples "examples.tfrecord.gz"