Skip to content

Instantly share code, notes, and snippets.

😂
Autistic Bot

Xuanliang Cui Yaoshicn

😂
Autistic Bot
Block or report user

Report or block Yaoshicn

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@dongweiming
dongweiming / resume.py
Created Oct 11, 2016
Python版本简历
View resume.py
#/usr/bin/env python
# coding=utf-8
import random
import re
def color(messages):
color = '\x1B[%d;%dm' % (1,random.randint(30,37))
return '%s %s\x1B[0m' % (color,messages)
View abu.sh
#!/bin/bash
function __main__(){
BACKUP_DIR=${HOME}/.autobackup
local op=${1}
shift
case ${op} in
"init")
init ${@}
@awjuliani
awjuliani / rl-tutorial-1.ipynb
Last active Apr 8, 2019
Reinforcement Learning Tutorial 1 (Two-armed bandit problem)
View rl-tutorial-1.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@bishboria
bishboria / springer-free-maths-books.md
Last active Dec 8, 2019
Springer made a bunch of books available for free, these were the direct links
@dannycastonguay
dannycastonguay / arch_vbox.md
Last active Nov 7, 2019
Installing Arch Linux on VirtualBox in Windows 10 for beginners
View arch_vbox.md

Installing Arch Linux on VirtualBox in Windows 10

I recently upgraded to a new system, and instead of running Arch Linux natively I've decided to run it inside VirtualBox on Windows 10. Below I note down the steps I took, which closely follow the excellent wiki pages of archlinux. But along the way, I also noted a few other steps steps I took to make this system very comfortable, which you'll have to figure out for yourself if you like them or not!

Setting up Windows 10 to be ready

There isn't much of preparation required, given that I started from scratch, but I did have to setup my windows environment a little bit.

  1. Install the windows package manager chocolatey
  2. Install qBittorrent (which will be used to download an iso copy of arch) by running the following command from the command line choco install qbittorrent (recommended to run the command line as an adm
@junzis
junzis / lowpass.py
Last active Nov 22, 2019
Python Lowpass Filter
View lowpass.py
# https://stackoverflow.com/questions/25191620/
# creating-lowpass-filter-in-scipy-understanding-methods-and-units
import numpy as np
from scipy.signal import butter, lfilter, freqz
from matplotlib import pyplot as plt
def butter_lowpass(cutoff, fs, order=5):
nyq = 0.5 * fs
@sevko
sevko / microtime.c
Created Mar 21, 2015
Get the current time in microseconds in C.
View microtime.c
#include <sys/time.h>
/**
* Returns the current time in microseconds.
*/
long getMicrotime(){
struct timeval currentTime;
gettimeofday(&currentTime, NULL);
return currentTime.tv_sec * (int)1e6 + currentTime.tv_usec;
}
@evi1m0
evi1m0 / PicConverText.py
Last active Nov 19, 2019
12306 新版验证码识别脚本 (已失效)
View PicConverText.py
#!/usr/bin/env python
# coding=utf8
# author=evi1m0
# website=linux.im
'''
12306 Captcha Picture:
author: Evi1m0@20150316
1. Download Captcha
2. Pic Conver Text
@floehopper
floehopper / install.md
Last active Nov 17, 2019
Install rtl-sdr on Raspian on Raspberry Pi
View install.md
jamesmead@floehopper.local:~$ sudo dd bs=1m if=/Users/jamesmead/Downloads/2015-02-16-raspbian-wheezy.img of=/dev/disk2
pi@raspberrypi ~ $ sudo raspi-config
# Choose option 1 to "Expand Filesystem" - Ensures that all of the SD card storage is available to the OS
# Choose Finish & reboot

pi@raspberrypi ~ $ sudo apt-get update
@fqrouter
fqrouter / readme.txt
Last active Oct 29, 2019
shadowsocks 公共代理的必要设置
View readme.txt
good, 你已经有了一个自己的shadowsocks代理了,现在想要把这个代理公布出去给所有人分享。
但是没有两个小时,代理就没法使用了,为什么?因为你需要额外注意以下事项(以下步骤需要比较高的linux技能)
本文只关注于确保shadowsocks服务还“活着”,如果你希望让其跑得更快,请参考
https://github.com/clowwindy/shadowsocks/wiki/Optimizing-Shadowsocks
1、 shadowsocks的timeout设置
超时时间越长,连接被保持得也就越长,导致并发的tcp的连接数也就越多。对于公共代理,这个值应该调整得小一些。推荐60秒。
2、 检查操作系统的各种限制
对于openvz的vps,特别需要检查一下
You can’t perform that action at this time.