Skip to content

Instantly share code, notes, and snippets.

View quevedin's full-sized avatar

Lucas Fernandez Seivane quevedin

View GitHub Profile
@quevedin
quevedin / README.md
Last active August 29, 2015 14:26 — forked from tmcw/README.md
GIS with Python, Shapely, and Fiona Example 1 - CSV Files
@quevedin
quevedin / boston.json
Last active August 29, 2015 14:26 — forked from pprett/boston.json
Decision Tree Viewer (D3 and Sklearn)
{"error": 42716.2954, "samples": 506, "value": [22.532806324110698], "label": "RM <= 6.94", "type": "split", "children": [{"error": 17317.3210, "samples": 430, "value": [19.93372093023257], "label": "LSTAT <= 14.40", "type": "split", "children": [{"error": 6632.2175, "samples": 255, "value": [23.349803921568636], "label": "DIS <= 1.38", "type": "split", "children": [{"error": 390.7280, "samples": 5, "value": [45.58], "label": "CRIM <= 10.59", "type": "split", "children": [{"error": 0.0000, "samples": 4, "value": [50.0], "label": "Leaf - 4", "type": "leaf"}, {"error": 0.0000, "samples": 1, "value": [27.9], "label": "Leaf - 5", "type": "leaf"}]}, {"error": 3721.1632, "samples": 250, "value": [22.90520000000001], "label": "RM <= 6.54", "type": "split", "children": [{"error": 1636.0675, "samples": 195, "value": [21.629743589743576], "label": "LSTAT <= 7.57", "type": "split", "children": [{"error": 129.6307, "samples": 43, "value": [23.969767441860473], "label": "TAX <= 222.50", "type": "split", "children": [{"err
@quevedin
quevedin / downloads.csv
Last active August 29, 2015 14:27 — forked from d3noob/.block
Simple Difference Chart
date_entered downloaded book_name
2015-04-19 5481 R Programming for Data Science
2015-04-19 23751 The Elements of Data Analytic Style
2015-04-20 5691 R Programming for Data Science
2015-04-20 23782 The Elements of Data Analytic Style
2015-04-21 6379 R Programming for Data Science
2015-04-21 23820 The Elements of Data Analytic Style
2015-04-22 7281 R Programming for Data Science
2015-04-22 23857 The Elements of Data Analytic Style
2015-04-23 7554 R Programming for Data Science
@quevedin
quevedin / server.R
Last active August 29, 2015 14:27 — forked from jcheng5/server.R
Adding raw HTML to Shiny apps
# Nothing to see here
shinyServer(function(input, output) {
})
@quevedin
quevedin / server.R
Last active August 29, 2015 14:27 — forked from withr/server.R
Encrypt password with md5 for Shiny-app.
library(shiny)
library(datasets)
Logged = FALSE;
PASSWORD <- data.frame(Brukernavn = "withr", Passord = "25d55ad283aa400af464c76d713c07ad")
# Define server logic required to summarize and view the selected dataset
shinyServer(function(input, output) {
source("www/Login.R", local = TRUE)
observe({
if (USER$Logged == TRUE) {
@quevedin
quevedin / selenium-screenshotting.md
Created March 22, 2016 09:52 — forked from dannguyen/selenium-screenshotting.md
Using Selenium and Python to screenshot a javascript-heavy page

Using Selenium and Python to screenshot a javascript-heavy page

As websites become more JavaScript heavy, it's harder to automate things like screenshotting for archival purposes. I've seen examples and suggestions to use PhantomJS for visual testing/archiving of websites, but have run into issues such as the non-rendering of webfonts. I've never tried out Selenium until today...and while I'm not thinking about performance implications yet, Selenium seems far more accurate than PhantomJS...which makes sense since it actually opens a real browser. And it's not too hard to script to do complex interactions: here's an [example of how to log in to Twitter, write a tweet, upload an image, and send a tweet via Selenium and DOM element selection](https://gist.github.com/dannguyen/8a6fa49253c1d6a0eb92

@quevedin
quevedin / odoo_requirements_pypy.txt
Created April 21, 2016 15:49 — forked from vuamitom/odoo_requirements_pypy.txt
Odoo 8 pip requirements.txt for Pypy
Babel==1.3
Jinja2==2.7.3
Mako==1.0.0
MarkupSafe==0.23
Pillow==2.5.1
http://download.gna.org/pychart/PyChart-1.39.tar.gz#egg=PyChart
PyYAML==3.11
Werkzeug==0.9.6
argparse==1.2.1
decorator==3.4.0
@quevedin
quevedin / growazureroot.sh
Created September 3, 2018 14:05 — forked from glennswest/growazureroot.sh
Grow Azure RHEL Root Value - Full Auto
echo "Grow Root FS"
rootdev=`findmnt --target / -o SOURCE -n`
rootdrivename=`lsblk -no pkname $rootdev`
rootdrive="/dev/"$rootdrivename
majorminor=`lsblk $rootdev -o MAJ:MIN | tail -1`
part_number=${majorminor#*:}
yum install -y cloud-utils-growpart.noarch
growpart $rootdrive $part_number -u on
xfs_growfs $rootdev
@quevedin
quevedin / java_install.sh
Created September 6, 2018 10:07 — forked from rjurney/java_install.sh
How to automagically install Oracle JDK 1.8 on CentOS
# Install Java 1.8 in CentOS/RHEL 6.X
sudo yum remove -y java-1.6.0-openjdk
wget --no-cookies \
--no-check-certificate \
--header "Cookie: oraclelicense=accept-securebackup-cookie" \
"http://download.oracle.com/otn-pub/java/jdk/8-b132/jdk-8-linux-x64.rpm" \
-O jdk-8-linux-x64.rpm
sudo rpm -Uvh jdk-8-linux-x64.rpm
sudo alternatives --install /usr/bin/java java /usr/java/jdk1.8.0/jre/bin/java 20000
sudo alternatives --install /usr/bin/jar jar /usr/java/jdk1.8.0/bin/jar 20000
@quevedin
quevedin / nvidia-docker2-deploy-ubuntu-16.04LTS.md
Created September 20, 2018 08:15 — forked from Brainiarc7/nvidia-docker2-deploy-ubuntu-16.04LTS.md
How to correctly install nvidia-docker2 on Ubuntu 16.04LTS

How to install NVIDIA Docker 2 package on Ubuntu and Debian:

If you came to this result (from Google or elsewhere) after realizing that Nvidia-docker's entry on this subject does not result in a working installation, here are the basic steps needed to install this package correctly:

For starters, ensure that you've installed the latest Docker Community edition by following the steps below:

curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -
sudo apt-key fingerprint 0EBFCD88

sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable"