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
import pandas as pd | |
import seaborn as sns | |
import numpy as np | |
import matplotlib.pyplot as plt | |
import matplotlib.ticker as ticker | |
pd.set_option('display.max_columns', None) | |
pd.set_option('display.max_rows', 100) | |
pd.set_option('display.min_rows', 50) | |
pd.set_option('display.max_colwidth', None) |
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
import re | |
def remove_parenthetical(input_string): | |
regex = re.compile("([\(\[]).*?([\)\]])") | |
return re.sub(regex, '', input_string).strip() |
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 tensorflow.compat.v1 import ConfigProto | |
from tensorflow.compat.v1 import InteractiveSession | |
config = ConfigProto() | |
config.gpu_options.per_process_gpu_memory_fraction = 0.6 | |
config.gpu_options.allow_growth = True | |
session = InteractiveSession(config=config) |
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
#!/bin/bash | |
if pgrep flite > /dev/null | |
then | |
killall flite | |
else | |
xsel | flite -voice /usr/share/tts-voices/cmu_us_ljm.flitevox | |
fi |
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
// Protractor configuration file, see link for more information | |
// https://github.com/angular/protractor/blob/master/lib/config.ts | |
const { SpecReporter } = require('jasmine-spec-reporter'); | |
exports.config = { | |
allScriptsTimeout: 11000, | |
specs: [ | |
'./e2e/**/*.e2e-spec.ts' | |
], |
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
// Karma configuration file, see link for more information | |
// https://karma-runner.github.io/1.0/config/configuration-file.html | |
module.exports = function (config) { | |
config.set({ | |
basePath: '', | |
frameworks: ['jasmine', '@angular-devkit/build-angular'], | |
plugins: [ | |
require('karma-jasmine'), | |
require('karma-chrome-launcher'), |
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
#!/bin/bash | |
if [[ $EUID -ne 0 ]]; then | |
echo "[!!] This script must be run as root" | |
exit 1 | |
fi | |
wget -nv https://download.opensuse.org/repositories/shells:fish:release:2/Debian_9.0/Release.key -O Release.key | |
apt-key add - < Release.key |
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
function prompt_user_input(message, defualt_value) | |
print(message) | |
input = readline() | |
value_entered =(input.len > 0) && (input.len < 128) | |
return value_entered ? input : defualt_value | |
end | |
function prompt_user_cont() | |
return contains(==, lowercase(prompt_user_input("We still doin' dis? [Y/n]: ", "y")), 'y') | |
end |
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
require 'ipaddr' | |
require 'nokogiri' | |
# Helper functions | |
def debug_message(output) | |
puts "[##] Debug: #{output}" | |
end | |
def pluralize(subject) | |
's' if subject.size > 1 |
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
#!/bin/bash | |
# Setup docker-ce and docker compose | |
if [[ $EUID -ne 0 ]]; then | |
echo "This script must be run as root" | |
exit 1 | |
fi | |
dockerComposeVersion=1.15.0 # latest version of compose as of 8/2/17 |
NewerOlder