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
| import requests | |
| from bs4 import BeautifulSoup | |
| from ebooklib import epub | |
| url = 'https://bigbangtrans.wordpress.com/' | |
| chapters = [] | |
| def init(): | |
| book = epub.EpubBook() |
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
| import requests | |
| from bs4 import BeautifulSoup | |
| from ebooklib import epub | |
| url = 'https://fangj.github.io/friends/' | |
| chapters = [] | |
| def init(): | |
| book = epub.EpubBook() |
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
| import re | |
| import requests | |
| from itertools import count | |
| from pathlib import Path | |
| from bs4 import BeautifulSoup | |
| from clint.textui import progress | |
| import sys | |
| SCAN_PAGES = 2 | |
| NUM_DOWNLOADS = 17 |
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
| from pandas import Series, DataFrame | |
| from matplotlib import pyplot | |
| from pandas.plotting import scatter_matrix | |
| # df = DataFrame.from_csv('stat_MCX1_1GRi3.csv') | |
| df = DataFrame.from_csv('stat_MCX1_2GRi3F_4TSi3_1TSi4.csv') | |
| print(df.head()) | |
| # https://stackoverflow.com/questions/21164910/how-do-i-delete-a-column-that-contains-only-zeros-in-pandas | |
| df = df.loc[:, (df != 0).any(axis=0)] |
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/python | |
| import matplotlib.pyplot as plt | |
| import scipy as sp | |
| import numpy as np | |
| import sys | |
| def usage(): | |
| print "This command draw x,y chart from tsv file" | |
| print "Usage:" |
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
| from subprocess import call | |
| # http://stackoverflow.com/questions/12030074/generate-list-of-numbers-in-specific-format | |
| ''' | |
| Download English Podcasts named xxxx-01.mp3, xxx-02.mp3, ..., xxx-10.mp3 | |
| ''' | |
| for i in range(5, 11): | |
| call(['wget', 'http://c0953132.cdn.cloudfiles.rackspacecloud.com/elementary-podcasts-s01-e%.2d.mp3' %i]) | |
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
| #define serial_test Serial1 | |
| void setup() { | |
| serial_test.begin(9600); | |
| } | |
| void loop() { | |
| if (serial_test.available()) { | |
| serial_test.write(serial_test.read()); | |
| } |
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
| #include <Servo.h> | |
| #define PWMOUT1 9 | |
| Servo esc; | |
| int input_degree; | |
| void setup() | |
| { | |
| Serial.begin(9600); // Comms with computer | |
| Serial.print("Started...\r\n"); |
NewerOlder