Skip to content

Instantly share code, notes, and snippets.

Avatar
👋
working on some blockchain stuff

Dixing (Dex) Xu dexhunter

👋
working on some blockchain stuff
View GitHub Profile
@dexhunter
dexhunter / 10g-nccl-fast.json
Last active Jul 1, 2021
horovod timeline json
View 10g-nccl-fast.json
[
{"name": "process_name", "ph": "M", "pid": 0, "args": {"start_time_since_epoch_in_micros":1624937181806323}},
{"name": "process_sort_index", "ph": "M", "pid": 0, "args": {"sort_index": 0}},
{"name": "process_name", "ph": "M", "pid": 1, "args": {"name": "allreduce.noname.1"}},
{"name": "process_sort_index", "ph": "M", "pid": 1, "args": {"sort_index": 1}},
{"ph": "B", "name": "NEGOTIATE_ALLREDUCE", "ts": 3399382, "pid": 1},{"ph": "X", "name": "8", "ts": 3399384, "pid": 1, "dur": 0},{"ph": "X", "name": "9", "ts": 3399390, "pid": 1, "dur": 0},{"ph": "X", "name": "10", "ts": 3399392, "pid": 1, "dur": 0},{"ph": "X", "name": "11", "ts": 3399393, "pid": 1, "dur": 0},{"ph": "X", "name": "5", "ts": 7133998, "pid": 1, "dur": 0},{"ph": "X", "name": "4", "ts": 7207126, "pid": 1, "dur": 0},{"ph": "X", "name": "15", "ts": 7239969, "pid": 1, "dur": 0},{"ph": "X", "name": "7", "ts": 7248450, "pid": 1, "dur": 0},{"ph": "X", "name": "6", "ts": 7255862, "pid": 1, "dur": 0},{"ph": "X", "name": "13", "ts": 7283415, "pid": 1, "du
@dexhunter
dexhunter / 2dmesh.cc
Last active Jun 14, 2021
2d mesh algorithm in horovod (based on NCCLHierarchicalAllreduce)
View 2dmesh.cc
#if HAVE_MPI
Status
NCCL2DMesh::Execute(std::vector<TensorTableEntry>& entries,
const Response& response) {
auto& first_entry = entries[0];
// Determine GPU IDs of the devices participating in this communicator.
std::vector<int32_t> nccl_device_map;
nccl_device_map.reserve(
global_state_->controller->GetLocalCommRanks().size());
View test.java
public interface FitnessCustomer {
private static enum Level {
BRONZE, SILVER, GOLD
}
private Level level;
public void setLevel(Level level) {
this.level = level;
}
public Level getLevel() {
return this.level;
@dexhunter
dexhunter / daemon.json
Created Feb 24, 2020
public /etc/docker/daemon.json
View daemon.json
{
"registry-mirrors" : [
"http://registry.docker-cn.com",
"http://docker.mirrors.ustc.edu.cn",
"http://hub-mirror.c.163.com",
"http://ovfftd6p.mirror.aliyuncs.com"
],
"insecure-registries" : [
"registry.docker-cn.com",
"docker.mirrors.ustc.edu.cn"
@dexhunter
dexhunter / hosts-github-cn
Created Feb 9, 2020
Github hosts for China
View hosts-github-cn
192.30.253.112 github.com
192.30.253.113 github.com
192.30.253.119 gist.github.com
151.101.185.194 github.global.ssl.fastly.net
151.101.100.133 assets-cdn.github.com
151.101.100.133 raw.githubusercontent.com
View docker-compose-simple.yaml
version: '2'
services:
orderer:
container_name: orderer
image: hyperledger/fabric-orderer
environment:
- FABRIC_LOGGING_SPEC=debug
- ORDERER_GENERAL_LISTENADDRESS=orderer
- ORDERER_GENERAL_BOOTSTRAPMETHOD=file
View alacritty.yml
# Configuration for Alacritty, the GPU enhanced terminal emulator.
# Any items in the `env` entry below will be added as
# environment variables. Some entries may override variables
# set by alacritty itself.
#env:
# TERM variable
#
# This value is used to set the `$TERM` environment variable for
# each instance of Alacritty. If it is not present, alacritty will
@dexhunter
dexhunter / gist-reveal.it-slides.html
Created Nov 12, 2018 — forked from ryanj/gist-reveal.it-slides.html
Gist-powered Revealjs slideshow presentations http://gist-reveal.it
View gist-reveal.it-slides.html
<section data-background-transition='zoom' data-transition='concave' data-background='http://ryanjarvinen.com/presentations/shared/img/broadcast_reveal_dark.png' data-state='blackout'>
<h2>Gist-Powered</h2>
<h1>Reveal.js</h1>
<h2>Slideshow Presentations</h2>
<br/>
<h1 class='fragment grow'><a style='color:deepskyblue;' href='http://gist-reveal.it'>gist-reveal.it</a></h1>
</section>
<section data-background-transition='zoom' data-transition='linear' id='try-it'>
<h2>Try it out!</h2>
<p>Create your own deck by forking a copy of <a href='https://gist.github.com/ryanj/af84d40e58c5c2a908dd'>this github gist</a>: <br /><a href='https://gist.github.com/ryanj/af84d40e58c5c2a908dd'>https://gist.github.com/ryanj/af84d40e58c5c2a908dd</a></p>
@dexhunter
dexhunter / sdk-py-tutorial.md
Last active Sep 4, 2018
fabric python sdk tutorial
View sdk-py-tutorial.md

Tutorial of using Fabric SDK

Notice: The tutorial is still in-progress, feel free to ask question in the rktchat channel. Code can be found at e2e_test.py.

Pre-requisites

Install Fabric SDK

@dexhunter
dexhunter / introrx.md
Created Jun 17, 2018 — forked from staltz/introrx.md
The introduction to Reactive Programming you've been missing
View introrx.md