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
# Screen Options ## | |
shell bash # Tell screen your default shell | |
startup_message off # Turn off start message | |
defscrollback = 5000 | |
shelltitle '$ |bash' # Dynamic window titled for running program | |
msgwait 1 # Set messages timeout to one second | |
nethack on # Turn on nethack error messages | |
backtick 0 0 0 whoami # Set "%0`" to equal the output of "whoami" | |
escape ^Oo |
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 | |
# Converts a mysqldump file into a Sqlite 3 compatible file. It also extracts the MySQL `KEY xxxxx` from the | |
# CREATE block and create them in separate commands _after_ all the INSERTs. | |
# Awk is choosen because it's fast and portable. You can use gawk, original awk or even the lightning fast mawk. | |
# The mysqldump file is traversed only once. | |
# Usage: $ ./mysql2sqlite mysqldump-opts db-name | sqlite3 database.sqlite | |
# Example: $ ./mysql2sqlite --no-data -u root -pMySecretPassWord myDbase | sqlite3 database.sqlite |
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/bash | |
# This script record your desktop. It calculates your screen resoltion and saves | |
# the video in ~/Video/output.mkv file. | |
# [email protected] | |
Xaxis=$(xrandr -q | grep '*' | uniq | awk '{print $1}' | cut -d 'x' -f1) | |
Yaxis=$(xrandr -q | grep '*' | uniq | awk '{print $1}' | cut -d 'x' -f2) | |
ffmpeg -f x11grab -s $(($Xaxis))x$(($Yaxis)) -r 25 -i :0.0 -sameq ~/Video/output.mkv |
This file has been truncated, but you can view the full file.
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
# 1 "ZombieReac.cpp" | |
# 1 "/home/dilawar/Work/NCBS/moose_svn1.7/moose/branches/async_multiscale_cmake/ksolve//" | |
# 1 "<command-line>" | |
# 1 "/usr/include/stdc-predef.h" 1 3 4 | |
# 30 "/usr/include/stdc-predef.h" 3 4 | |
# 1 "/usr/include/i386-linux-gnu/bits/predefs.h" 1 3 4 | |
# 31 "/usr/include/stdc-predef.h" 2 3 4 | |
# 1 "<command-line>" 2 | |
# 1 "ZombieReac.cpp" | |
# 10 "ZombieReac.cpp" |
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 | |
try: | |
import ConfigParser as cfg | |
except: | |
import configparser as cfg | |
import os | |
import json | |
import sys |
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
M1719: |Labc|Ldce|Ebze| 0.20 0.30 0.32 0.32 0.32 0.32 0.263296394963 0.111387109786 0.470177600114 0.029771700191 0.173209325064 3.28129207574 |
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
""" | |
Animation of a head slicing. | |
Based on a BSD-like licenced code by Gael Varoquaux | |
http://docs.enthought.com/mayavi/mayavi/auto/example_mri.html | |
Result: | |
http://i.imgur.com/EJZELfi.gif | |
""" |
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
# Generate noise frames | |
# dependencies: psychopy, python-numpy, python-pyglet | |
from numpy import random | |
from psychopy import visual | |
# create a window | |
win = visual.Window([800, 600], monitor="testMonitor", units="deg") | |
maskDuration = 180 # Duration of mask in frames | |
visualNoiseSize = 512 # Dimension in pixels of visual noise. Must be a power of 2 |
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
"""query.py: | |
Searches each row of query sheet in columns of database sheet. | |
""" | |
__author__ = "Dilawar Singh" | |
__copyright__ = "Copyright 2015, Dilawar Singh and NCBS Bangalore" | |
__credits__ = ["NCBS Bangalore"] | |
__license__ = "GNU GPL" |
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
def count_spikes(tables, threshold): | |
'''Count the number of spikes, also pupulate the spikeTables ''' | |
nSpikes = 0 | |
spikeBegin = False | |
spikeEnds = False | |
clock = moose.Clock('/clock') | |
for tname in tables: | |
t = tables[tname] | |
dt = clock.currentTime / len(t.vector) | |
spikeList = [] |
OlderNewer