Skip to content

Instantly share code, notes, and snippets.

View juniorUsca's full-sized avatar

Junior Usca juniorUsca

View GitHub Profile
@juniorUsca
juniorUsca / generate_persons.js
Last active August 1, 2016 09:48
Generar personas para MongoDB
var nombres_synapticos = [ "Sergio Stanclift", "Robert Marceaux", "Martine Colle", "Hobert Shoptaw", "Danyell Steinruck", "Terry Villaluz", "Cammie Vandegrift", "Claire Vitale", "Shante Stlaurent", "Marnie Hiteman", "Shavonda Darter", "Myrle Schehr", "Clare Bowey", "Mittie Boldosser", "Stephenie Entwisle", "Frida Melendes", "Tawny Hankin", "Tinisha Decardo", "Augustus Schmuhl", "Will Jufer", "Jeni Keyl", "Angelika Cantillo", "Lenny Pietz", "Kati Liesmann", "Olivia Verdiguel", "Jeanice Jaruis", "Dawne Czach", "Jacques Perez", "Janene Lizarraga", "Joanna Burchell", "Rossana Brettmann", "Markus Granizo", "Mia Tejera", "Gina Coutch", "Burt Winkowski", "Rea Morcos", "Yasmin Hollenshead", "Karena Immerman", "Jeanett Mcanelly", "Teddy Vogl", "Kelle Jankoski", "Narcisa Hsun", "Lelah Matheson", "Elda Damiani", "Farah Krenke", "Sharan Konek", "Andrew Yennard", "Tanesha Tilford" ];
var intereses_synapticos = [ "musica", "arte", "juegos", "peliculas", "anime", "vida", "amanecer", "amor", "familia", "tv", "medio ambiente
@juniorUsca
juniorUsca / map_reduce.js
Created August 1, 2016 18:36
Funciones de map reduce para sumar los intereses de las personas por pais
/// SUMA DE INTERESES POR PAIS
var mapFun = function () {
var intereses = {};
for (var i = this.intereses.length - 1; i >= 0; i--) {
intereses[ this.intereses[i] ] = 1;
}
emit( this.pais, intereses );
};
var reduceFun = function (key, value) {
var temp = value[value.length-1];
@juniorUsca
juniorUsca / Create Centroids
Created August 4, 2016 21:40
Clustering in Neo4j
CREATE (:Centroid {musica: 126, arte: 16, juegos: 44, peliculas: 116, anime: 70, vida: 95, amanecer: 26, amor: 127, familia: 148, tv: 142, medio_ambiente: 118, mechanotherapeutic: 136, protectorate: 135, phytopaleontological: 143, springlet: 35, diectasis: 24, sconcheon: 60, noncompetitive: 76, bellonion: 24, hami: 142, accusable: 99, operatable: 123, linitis: 30, hoastman: 15, unlanguid: 62, isokurtic: 103, benchboard: 113, gastroplication: 120, alumiferous: 45, chapterful: 134, yeldrock: 81, axopodia: 41, smokebox: 23, fireworky: 107, semideltaic: 62, intimation: 101, tarsioid: 142, fotui: 146, woft: 128, Mandingo: 48, pretincture: 60, pamper: 19, extraneously: 25, consternation: 27, malleate: 109, thisn: 31, ribbony: 100, Lapland: 70, Monticulipora: 118, cetylene: 80, fie: 89, pluvious: 72, gunl: 99, monsieur: 81, producal: 80, Limnophilidae: 114, daitya: 114, octahedral: 146, pegger: 13, index:1, iteration:1 });
CREATE (:Centroid {musica: 58, arte: 59, juegos: 114, peliculas: 127, anime: 97, vida: 118, am
@juniorUsca
juniorUsca / tensor flow classifier example.md
Last active May 4, 2017 16:14
Tensorflow classifier example
  1. Instalar docker
curl -sSL https://get.docker.com/ | sh
sudo usermod -aG docker <tu-usuario>
  1. Descargar un dataset y organizar las imagenes en formato jpg por carpetas
@juniorUsca
juniorUsca / hosts
Last active September 21, 2018 06:25
Block Social Media
127.0.0.1 es-la.facebook.com
127.0.0.1 web.facebook.com
127.0.0.1 m.facebook.com
127.0.0.1 facebook.com
127.0.0.1 www.facebook.com
127.0.0.1 youtube.com
127.0.0.1 www.youtube.com
127.0.0.1 spotify.com
127.0.0.1 www.spotify.com
127.0.0.1 instagram.com
@juniorUsca
juniorUsca / docker-compose.yml
Created October 4, 2018 17:48
odoo docker compose
version: '3'
services:
web:
image: odoo:11.0
depends_on:
- db
ports:
- 80:8069
- 443:8071
volumes:
@juniorUsca
juniorUsca / trial.md
Created January 16, 2019 16:40 — forked from satish-setty/trial.md
Beyond Compare 4 license for Linux

Beyond Compare 4.x

Licensed to: ASIO Allsoftinone Quantity: 1 user Serial number: 1822-9597 License type: Pro Edition for Linux

First delete away trial mode:

sudo sed -i "s/keexjEP3t4Mue23hrnuPtY4TdcsqNiJL-5174TsUdLmJSIXKfG2NGPwBL6vnRPddT7tH29qpkneX63DO9ECSPE9rzY1zhThHERg8lHM9IBFT+rVuiY823aQJuqzxCKIE1bcDqM4wgW01FH6oCBP1G4ub01xmb4BGSUG6ZrjxWHJyNLyIlGvOhoY2HAYzEtzYGwxFZn2JZ66o4RONkXjX0DF9EzsdUef3UAS+JQ+fCYReLawdjEe6tXCv88GKaaPKWxCeaUL9PejICQgRQOLGOZtZQkLgAelrOtehxz5ANOOqCaJgy2mJLQVLM5SJ9Dli909c5ybvEhVmIC0dc9dWH+/N9KmiLVlKMU7RJqnE+WXEEPI1SgglmfmLc1yVH7dqBb9ehOoKG9UE+HAE1YvH1XX2XVGeEqYUY-Tsk7YBTz0WpSpoYyPgx6Iki5KLtQ5G-aKP9eysnkuOAkrvHU8bLbGtZteGwJarev03PhfCioJL4OSqsmQGEvDbHFEbNl1qJtdwEriR+VNZts9vNNLk7UGfeNwIiqpxjk4Mn09nmSd8FhM4ifvcaIbNCRoMPGl6KU12iseSe+w+1kFsLhX+OhQM8WXcWV10cGqBzQE9OqOLUcg9n0krrR3KrohstS9smTwEx9olyLYppvC0p5i7dAx2deWvM1ZxKNs0BvcXGukR+/g" /usr/lib/beyondcompare/BCompare
https://facturacionelectronica.us/facturacion/controller/ws_consulta_rucdni_v2.php?usuario=10733298214&password=mypassword&documento=DNI&nro_documento=47077319
@juniorUsca
juniorUsca / outsider.js
Created February 14, 2019 07:43 — forked from fazlurr/outsider.js
React Detect Click Outside Component - https://stackoverflow.com/a/42234988
/**
* Component that alerts if you click outside of it
*/
class OutsideAlerter extends Component {
constructor(props) {
super(props);
this.setWrapperRef = this.setWrapperRef.bind(this);
this.handleClickOutside = this.handleClickOutside.bind(this);
}
USE [RRHH]
DECLARE @tnEmpresa TINYINT = 1;
DECLARE @tnOrganizacion SMALLINT = 16;
DECLARE @tnNivelTrabajador TINYINT = 1;
DECLARE @tnNumero INT = 1;
DECLARE @ltbAsistencia TABLE
(