- Phage lambda
- Phi X 174
- SV40
- T4 phage
- Tobacco mosaic virus
- Herpes simplex virus
This file contains 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
nnoremap <silent> <leader><space> :call SaveAndExecutePython()<CR> | |
vnoremap <silent> <leader><space> :<C-u>call SaveAndExecutePython()<CR> | |
" https://stackoverflow.com/questions/18948491/running-python-code-in-vim | |
function! SaveAndExecutePython() | |
" SOURCE [reusable window]: https://github.com/fatih/vim-go/blob/master/autoload/go/ui.vim | |
" save and reload current file | |
silent execute "update | edit" |
This file contains 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
# MXNet Autoencoder | |
# based on example from SherlockLiao | |
# https://github.com/SherlockLiao/mxnet-gluon-tutorial/blob/master/08-AutoEncoder/simple_autoencoder.py | |
import operator | |
import bisect | |
import os | |
import numpy as np | |
import mxnet as mx | |
from mxnet import gluon |
Digital Music systems such as MIDI use integers to represent different notes. This method of representation is known an enumeration. For this exercise, we will write a program to build a hash table that translates note values to numerical values, and an array to translate numerical values back to note values. In order to accomplish this, we will need to know two pieces of information, and let our program enumerate our two lookup tables.
- What are the two pieces of information our program needs to enumerate the tables?
- Why use a hash table for note lookups, and an array for numerical lookups?
For now, we will ignore sharps and flats, and just utilize the "white keys" of a piano when building our table. A full octave is represented by eight notes: C D E F G A B C
. When specifying note values, we will use scientific pitch notation.
- How many full octaves can we enumerate with an 8-bit unsigned integer? h
This file contains 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 Bio.Blast import NCBIWWW | |
from Bio.Blast import NCBIXML | |
import random | |
def random_sequence_generator(length): | |
return str.join('', [random.choice('AGTC') for x in range(length)]) | |
def gc_good(sequence, ideal=.5, spread=.05): | |
val = (sequence.count('G') + sequence.count('C')) / float(len(sequence)) | |
return (ideal - spread) < val < (ideal + spread) |
This file contains 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: latin-1 -*- | |
import google | |
import requests | |
import magic | |
def get_pdf(url, title): | |
print url | |
pdf = requests.get(url) | |
with magic.Magic() as m: |
This file contains 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
ghall@littletit:[~/code/chainsaw/python] python vt_passwd.py -p /dev/ttyUSB2 | |
Sun Jul 4 20:28:38 2010 | |
____ _ ____ ______ _____ ____ ____ | |
| _ \ / \ / ___/ ___\ \ / / _ \| _ \| _ \ _ _ | |
| |_) / _ \ \___ \___ \\ \ /\ / / | | | |_) | | | | (_|_) | |
| __/ ___ \ ___) |__) |\ V V /| |_| | _ <| |_| | _ _ | |
|_| /_/ \_\____/____/ \_/\_/ \___/|_| \_\____/ (_|_) | |
This file contains 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
$0=40.020 (x, step/mm) | |
$1=40.020 (y, step/mm) | |
$2=320.000 (z, step/mm) | |
$3=30 (step pulse, usec) | |
$4=500.000 (default feed, mm/min) | |
$5=500.000 (default seek, mm/min) | |
$6=224 (step port invert mask, int:11100000) | |
$7=255 (step idle delay, msec) | |
$8=25.000 (acceleration, mm/sec^2) | |
$9=0.050 (junction deviation, mm) |
This file has been truncated, but you can view the full file.
This file contains 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
M140 S100.000000 | |
M109 T0 S230.000000 | |
T0 | |
M190 S100.000000 | |
;Sliced at: Wed 26-11-2014 21:39:25 | |
;Basic settings: Layer height: 0.1 Walls: 0.8 Fill: 100 | |
;Print time: #P_TIME# | |
;Filament used: #F_AMNT#m #F_WGHT#g | |
;Filament cost: #F_COST# | |
;M190 S100 ;Uncomment to add your own bed temperature line |
This file contains 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
2014-11-28 15:26:04,034 - octoprint.server.util.sockjs - INFO - New connection from client: 192.168.1.8 | |
2014-11-28 15:30:00,578 - octoprint.util.comm - ERROR - Something crashed inside the serial connection loop, please report this in OctoPrint's bug tracker: | |
Traceback (most recent call last): | |
File "/home/ghall/local/octoprint/local/lib/python2.7/site-packages/OctoPrint-1.2.0_dev_242_g084ca95-py2.7.egg/octoprint/util/comm.py", line 924, in _monitor | |
self._sendNext() | |
File "/home/ghall/local/octoprint/local/lib/python2.7/site-packages/OctoPrint-1.2.0_dev_242_g084ca95-py2.7.egg/octoprint/util/comm.py", line 1036, in _sendNext | |
self._changeState(self.STATE_OPERATIONAL) | |
File "/home/ghall/local/octoprint/local/lib/python2.7/site-packages/OctoPrint-1.2.0_dev_242_g084ca95-py2.7.egg/octoprint/util/comm.py", line 218, in _changeState | |
self._callback.mcStateChange(newState) | |
File "/home/ghall/local/octoprint/local/lib/python2.7/site-packages/OctoPrint-1.2.0_dev_242_g084ca95-py2.7.egg/octoprint/printer.py |
NewerOlder