0%

1
2
3
4
5
6
7
8
9
10
jupyter --path

config:
/usr/local/etc/jupyter
/etc/jupyter
data:
/usr/local/share/jupyter
/usr/share/jupyter
runtime:
/run/user/1005/jupyter

进入/usr/local/share/jupyter 下的kernels
修改pyenv3.6/kernel.json 中的python地址

1
/home/username/.pyenv/versions/3.6.2/envs/env3.6.2/bin/python3

vim

1
:set ff=unix

可以去掉\r\n中的\r

1
2
3
4
5
6
7
8
9
10
11
12
13
14
import h5py  #导入工具包  
import numpy as np
#HDF5的写入:
imgData = np.zeros((30,3,128,256))
f = h5py.File('HDF5_FILE.h5','w') #创建一个h5文件,文件指针是f
f['data'] = imgData #将数据写入文件的主键data下面
f['labels'] = range(100) #将数据写入文件的主键labels下面
f.close() #关闭文件

#HDF5的读取:
f = h5py.File('HDF5_FILE.h5','r') #打开h5文件
f.keys() #可以查看所有的主键
a = f['data'][:] #取出主键为data的所有的键值
f.close()

https://blog.csdn.net/leibaojiangjun1/article/details/53635353

1
2
sudo apt-get install axel
axel -n 10 -a -S5 ftp://ftp.kernel.org/pub/linux/kernel/v2.6/linux-2.6.9.tar.gz -o /media/MD-Data/

安装环境的时候使用conda安装失败,使用pyenv成功.

1
2
3
4
ansible group --become --ask-become-pass -m command -a 'my command'

ansible group -m copy -a "src=test.sh dest=~/test.sh mode=0755"
ansible group -m shell -a "./test.sh"

https://www.jianshu.com/p/1bf79764bb6f

1
2
a = np.empty([1, 56])
np.append(a, b)

1
2
3
np.savez(outfile, detections)
npzfile = np.load("detections.save.npz")
print(npzfile["arr_0"])