- 第一章 认识并行计算和Python
- 1. 介绍
- 2. 并行计算的内存架构
- 3. 内存管理
- 4. 并行编程模型
- 5. 如何设计一个并行程序
- 6. 如何评估并行程序的性能
- 7. 介绍Python
- 8. 并行世界的Python
- 9. 介绍线程和进程
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 | |
git add -A | |
git commit --amend --no-edit | |
git push -f |
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
#!/usr/bin/env python | |
""" | |
在命令行将python timestamp转换成人类可读的时间 | |
Usage: pytp 1514131200 | |
2017-12-25 00:00:00 +0800 | |
""" | |
from __future__ import unicode_literals |
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
#!/usr/bin/env python | |
# -*- coding: utf-8 -*- | |
""" | |
在命令行将python timestamp转换成人类可读的时间 | |
Usage: pytp 1514131200 | |
2017-12-25 00:00:00 +0800 | |
""" |
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
#!/usr/bin/env python | |
# -*- coding: utf-8 -*- | |
""" | |
在命令行将javascript timestamp转换成人类可读的时间 | |
Usage: | |
jstp 1506589075352 | |
2017-09-28 16:57:55 +0800 | |
""" |
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
git fetch -p && for branch in `git branch -vv | grep ': gone]' | awk '{print $1}'`; do git branch -D $branch; done |
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
### Keybase proof | |
I hereby claim: | |
* I am laixintao on github. | |
* I am laixintao (https://keybase.io/laixintao) on keybase. | |
* I have a public key ASAXX1tQyNKE6dLz54dGGPFBGGEnJeg1l3OHqnnCjsszOwo | |
To claim this, I am signing this object: |
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
for i in {0..255}; do | |
printf "\x1b[38;5;${i}mcolour${i}\x1b[0m\n" | |
done |
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
# -*- coding: utf-8 -*- | |
"""将excel转换成json""" | |
import json | |
import pandas | |
import numpy | |
courts = pandas.read_excel("courts.xlsx") |