Skip to content

Instantly share code, notes, and snippets.

Avatar

JP ferrouswheel

View GitHub Profile
@ferrouswheel
ferrouswheel / add_glue_partitions.py
Created Apr 24, 2020 — forked from JoaoCarabetta/add_glue_partitions.py
Add Glue Partitions with Lambda AWS
View add_glue_partitions.py
import json
import boto3
from dateutil import rrule
from datetime import datetime, timedelta
glue = boto3.client('glue', '--') # Update with your location
s3 = boto3.client('s3')
def get_current_schema(table_name, database_name):
@ferrouswheel
ferrouswheel / Synology-Diskstation-Git.md
Created Oct 2, 2018 — forked from walkerjeffd/Synology-Diskstation-Git.md
Instructions for setting up git server on Synology Diskstation
View Synology-Diskstation-Git.md

Configure Synology NAS as Git Server

Instructions for setting up a git server on a Synology NAS with Diskstation. Specifically, I am using a DS414 with DSM 5.0.

Set Up User and Folder

  • Create user gituser via Diskstation interface (with File Station and WebDAV privilages)
  • Add new shared folder called git (located at /volume1/git) with read/write access for gituser and admin. This folder will hold all the repos.
  • Install Git Server package via Diskstation
@ferrouswheel
ferrouswheel / gist:a547be2fe5b2ae683c8aac45f271560c
Created Aug 3, 2018 — forked from luckydev/gist:b2a6ebe793aeacf50ff15331fb3b519d
Increate max no of open files limit in Ubuntu 16.04 for Nginx
View gist:a547be2fe5b2ae683c8aac45f271560c
# maximum capability of system
user@ubuntu:~$ cat /proc/sys/fs/file-max
708444
# available limit
user@ubuntu:~$ ulimit -n
1024
# To increase the available limit to say 200000
user@ubuntu:~$ sudo vim /etc/sysctl.conf
@ferrouswheel
ferrouswheel / Readme.md
Created Jan 14, 2017 — forked from myfavouritekk/Readme.md
Extract dense optical flow and save as grayscale or RGB images
View Readme.md

#Extract dense optical flow and save as grayscale or RGB images Copyright @ Kai Kang (myfavouritekk@gmail.com) 2016

##Dependencies

  • OpenCV 2 with Python interface
  • glob, numpy, siopy

##Usages

# help messages
@ferrouswheel
ferrouswheel / reclaimWindows10.ps1
Created Jan 9, 2017 — forked from alirobe/reclaimWindows10.ps1
"Reclaim Windows 10" turns off a bunch of unnecessary Windows 10 telemetery, removes bloatware, and privacy invasions. Review and tweak before running. Scripts for reversing are included and commented. Fork via https://github.com/Disassembler0 (different defaults)
View reclaimWindows10.ps1
##########
# Win10 Initial Setup Script
# Author: Disassembler <disassembler@dasm.cz>
# Version: 1.7, 2016-08-15
# dasm's script: https://github.com/Disassembler0/Win10-Initial-Setup-Script/
# THIS IS A PERSONALIZED VERSION
# This script leaves more MS defaults on, including MS security features.
# Tweaked based on personal preferences for @alirobe 2016-11-16 - v1.7.1
@ferrouswheel
ferrouswheel / Install NVIDIA Driver and CUDA.md
Created Nov 23, 2016 — forked from wangruohui/Install NVIDIA Driver and CUDA.md
Install NVIDIA Driver and CUDA on Ubuntu / CentOS / Fedora
View Install NVIDIA Driver and CUDA.md
@ferrouswheel
ferrouswheel / get_total_size.sh
Created Sep 26, 2016
Get size of executable and all dependencies
View get_total_size.sh
#!/bin/bash
resolve_path() {
# From https://github.com/keen99/shell-functions/tree/master/resolve_path
#I'm bash only, please!
# usage: resolve_path <a file or directory>
# follows symlinks and relative paths, returns a full real path
#
local owd="$PWD"
#echo "$FUNCNAME for $1" >&2
View gpu_stat.py
#!/usr/bin/env python
# gpu_stat.py [DELAY [COUNT]]
# dump gpu stats as a line of json
# {"time": 1474168378.146957, "pci_tx": 146000, "pci_rx": 1508000,
# "gpu_util": 42, "mem_util": 24, "mem_used": 11710,
# "temp": 76, "fan_speed": 44 }
@ferrouswheel
ferrouswheel / 3_install_deeplearning_libs.sh
Last active Dec 17, 2015 — forked from graphific/3_install_deeplearning_libs.sh
Installation script for Deep Learning Libraries on Ubuntu 14.04
View 3_install_deeplearning_libs.sh
#!/usr/bin/env bash
# Installation script for Deep Learning Libraries on Ubuntu 14.04, by Roelof Pieters (@graphific)
# BSD License
orig_executor="$(whoami)"
if [ "$(whoami)" == "root" ]; then
echo "running as root, please run as user you want to have stuff installed as"
exit 1
fi
###################################
@ferrouswheel
ferrouswheel / 2_test_gpu_cuda.sh
Last active Dec 17, 2015 — forked from graphific/2_test_gpu_cuda.sh
Test script for checking if Cuda and Drivers correctly installed on Ubuntu 14.04
View 2_test_gpu_cuda.sh
#!/usr/bin/env bash
set -e
# Test script for checking if Cuda and Drivers correctly installed on Ubuntu 14.04, by Roelof Pieters (@graphific)
# BSD License
if [ "$(whoami)" == "root" ]; then
echo "running as root, please run as user you want to have stuff installed as"
exit 1
You can’t perform that action at this time.