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
cat Pipfile.lock \ | |
| grep -B1 '"hashes"\|"version": ' \ | |
| grep -v '"markers": \|"hashes": ' \ | |
| grep ": {\|version" \ | |
| sed -e 's/: {$//g' \ | |
| tr '\n' ',' | tr -s ' ' ' ' \ | |
| sed -e 's/, "version": "//g;s/", "/ /g;s/"//g;s/,//g' \ | |
| tr ' ' '\n' \ | |
| grep -v "^$" > requirements.txt |
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
#### | |
# docker container processes | |
#### | |
# processes running in docker containers | |
> /tmp/docker.processes.txt | |
for i_container_id in $(docker ps | tr -s ' ' ',' | cut -d',' -f1 | grep -v CONTAINER) | |
do | |
CONTAINER_NAME=$(docker ps | tr -s ' ' ',' | grep "$i_container_id" | sed -e 's/.*,//g') | |
echo "# $i_container_id, $CONTAINER_NAME" | tee -a /tmp/docker.processes.txt |
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 __future__ import division | |
import numpy as np | |
import scipy | |
import traceback | |
import logging | |
from time import time | |
from redis import StrictRedis | |
import sys | |
import os.path |
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
# -*- coding: utf-8 -*- | |
# This file as well as the whole tsfresh package are licenced under the MIT licence (see the LICENCE.txt) | |
# Maximilian Christ (maximilianchrist.com), Blue Yonder Gmbh, 2016 | |
# https://gist.github.com/earthgecko/9e6f2f5c0d48d53ff34284a860a50cde | |
""" | |
This module contains the main function to interact with tsfresh: extract features | |
""" | |
from __future__ import absolute_import, division |
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
# -*- coding: utf-8 -*- | |
# This file as well as the whole tsfresh package are licenced under the MIT licence (see the LICENCE.txt) | |
# Maximilian Christ (maximilianchrist.com), Blue Yonder Gmbh, 2016 | |
# https://gist.github.com/earthgecko/9e6f2f5c0d48d53ff34284a860a50cde | |
""" | |
This module contains the main function to interact with tsfresh: extract features | |
""" | |
from __future__ import absolute_import, division |
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
# This gist is a basic example of adding Redis password to rebrow in a modified implementation of | |
# @elky84 https://github.com/marians/rebrow/pull/20 but using PyJWT to encode the password in the POST | |
# to a JWT token and a client token as a replacement for the plaintext password URL parameter. | |
# This example includes logging which is not in rebrow and this example rebrow stores the JWT encode string in Redis. | |
# With normal rebrow this would not be possible and Flask seesion or some internal Python method would need to be | |
# used. The version of rebrow that is used here is a version that embedded in another application that does have | |
# access to Redis, hence here rebrow stores the data in Redis, rebrow here requires auth and it is also run behind | |
# a SSL terminated endpoint and therefore the POST data is encrypted. If rebrow was just run as is, then the POST | |
# data would not be encrypted and the password would still be sent plaintext. |
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 | |
import numpy as np | |
import scipy | |
import statsmodels.api as sm | |
import traceback | |
import logging | |
from time import time | |
from msgpack import unpackb, packb | |
from redis import StrictRedis |
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
Who's neocortex has seen these before? | |
These panda scipy py27 py35 are probably buried in some change in pandas relating to some change is Python 3 | |
like range type changing from type list to class or similar. Please just scan through and see if any bells rings. | |
Perhaps a bell may ring on: | |
- AttributeError errors 'assertItemsEqual' in a few contexts, but the following may help to pin it down, specifically | |
- test_mass_quantile | |
- test_ar_coefficient |
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
# Find a change via a string in actually git diffs (not just commit messages) | |
GIT_REPO_DIR="<PATH_TO_YOU_REPO>" | |
TMP_DIR="/tmp" | |
STRING_TO_FIND="include openssh_server" | |
cd "$GIT_REPO_DIR" | |
> "${TMP_DIR}/git.rev.matches" | |
git rev-list HEAD | | |
while read rev; do |
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 | |
#### snype_skyline_analyzer.sh #### | |
# | |
#### | |
# DESCRIPTION | |
# This mitigates against analyzer running but it connection timing out | |
# | |
# THIS IS JUST A GIST | |
# THIS IS JUST A GIST |
NewerOlder