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
""" | |
La funcion envido, dada una lista de (estrictamente) tres cartas, | |
me devuelve el envido de esa mano de truco. | |
Cada elemento de la lista es de la forma: | |
carta = {'palo': 'xxx', 'numero': N} | |
""" | |
def carta_simple_envido(carta): | |
""" de una carta data obtiene cuanto suma al envido |
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
# add the repo with the driver | |
git clone git@github.com:nealey/hdjd.git | |
# install requirements | |
sudo apt install libusb libusb-1.0.0 libusb-1.0.0-dev libusb-dev libusb-1.0-0-dev libasound2-dev mixxx | |
# build the drivers | |
cd hdjd/ | |
make clean all |
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
{ | |
"swagger": "2.0", | |
"info": { | |
"version": "1.0.0", | |
"title": "Sigeva API" | |
}, | |
"basePath": "/v1", | |
"schemes": [ | |
"http", | |
"https" |
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
####################################### | |
#### CARGAR MAPAS DESDE DISTINTOS GEOSERVICIOS ###################### | |
################################################################## | |
rm(list=ls()) | |
library(sf) |
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
""" | |
Compare a data.json file with a google drive CSV | |
""" | |
import csv | |
import json | |
import os | |
import requests | |
def clean_url(url): |
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 json | |
import os | |
import requests | |
from slugify import slugify | |
instance_url = 'https://ckan.io' | |
package_list_url = 'api/3/action/package_list' | |
package_show_url = 'api/3/action/package_show' | |
expected_topics = [ |
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
# https://imagemagick.org/Usage/annotating/ | |
original_image=$1 | |
txt=$2 # texto a anotar | |
x1=$3 # Coord X (pixeles) donde empieza a escribir | |
y1=$4 # Coord Y (pixeles) donde empieza a escribir | |
color=$5 # ej 8808 | |
prefix=$6 # prefijo del nombre de archivo | |
convert $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
// requiere en variable map el mapa de google | |
function separar_superpuestos(round_decs=7) { | |
// revisar todo el mapa y detectar puntos superpuestos (o cercanos segun round de lat y lng) | |
let to_round = Math.pow(10, round_decs); | |
map.data.forEach(function(feature){ | |
let geom = feature.getGeometry(); | |
if (geom != null) { |
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
# El ID dew huawei es 12d1 | |
echo "0x12d1" > ~/.android/adb_usb.ini | |
# ver donde esta el dispositivo (conectado vua USB) | |
lsusb | |
# Bus 001 Device 009: ID 12d1:107e Huawei Technologies Co., Ltd. | |
# ver los pemisos | |
ls /dev/bus/usb/001/009 | |
sudo chmod 666 /dev/bus/usb/001/009 |
NewerOlder