Skip to content

Instantly share code, notes, and snippets.

View danielmoralesp's full-sized avatar
🎯
Focusing

Daniel M. danielmoralesp

🎯
Focusing
  • Software Engineer
  • Digital Nomad
View GitHub Profile
@danielmoralesp
danielmoralesp / SETTINGS.json
Last active June 21, 2021 13:36
DataSource.ai Competitions - SETTINGS.json
{
RAW_DATA_DIR: "./data/",
TRAIN_DATA_CLEAN_PATH: "./data/processed/train.csv",
TEST_DATA_CLEAN_PATH: "./data/processed/test.csv",
MODEL_CHECKPOINT_DIR: "./models/",
LOGS_DIR: "./logs/",
SUBMISSION_DIR: "./submissions/"
}
@danielmoralesp
danielmoralesp / README.md
Last active June 21, 2021 13:33
DataSource.ai Competitions - README.md

Hello!

Below you can find a outline of how to reproduce my solution for the competition. If you run into any trouble with the setup/code or have any questions please contact me at (email)

ARCHIVE CONTENTS

  • model.tgz : original model upload - contains original code, additional training examples, corrected labels, etc
  • comp_etc : contains ancillary information for prediction - clustering of training/test examples
  • comp_mdl : model binaries used in generating solution
  • comp_preds : model predictions
@danielmoralesp
danielmoralesp / model_directory_tree.txt
Created June 21, 2021 13:30
DataSource.ai Competitions - Directory Tree
.
./sample_comp_dir
./sample_comp_dir/documentation
./sample_comp_dir/EDA
./sample_comp_dir/code
./sample_comp_dir/logs
./sample_comp_dir/submissions
./sample_comp_dir/data
./sample_comp_dir/data/raw
./sample_comp_dir/data/processed
@danielmoralesp
danielmoralesp / requirements.txt
Created June 21, 2021 13:27
DataSource.ai Competitions - requirements.txt
autoflake==1.1
autopep8==1.3.5
flake8==3.5.0
h5py==2.7.1
Keras==2.1.4
numba==0.38.0
numpy==1.14.3
numpydoc==0.8.0
pandas==0.23.0
pandas-profiling==1.4.1
height weight
65.78 112.99
71.52 136.49
69.4 153.03
68.22 142.34
67.79 144.3
68.7 123.3
69.8 141.49
70.01 136.46
67.9 112.37
@danielmoralesp
danielmoralesp / gist:2979248b83931d9b90e49ce6c91e6464
Last active August 30, 2020 13:11
Digital Ocean + Rails 5.2 + Ubuntu 16.04 + Capistrano 3 + Passenger
# Inside Digital Ocean
create new project
name project (without resources)
get started with a droplet
settings: Ubuntu 16.04 + 10$ + USA-New York 3
create
digital ocean send an email with root password
# Setting root and deploy users
ssh root@IPADDRESS
import operator
from collections import Counter
import random
import numpy as np
np.random.seed(1)
random.seed(1)
def split(dataset, labels, column):
data_subsets = []
label_subsets = []
@danielmoralesp
danielmoralesp / jupyter.md
Created June 6, 2020 02:11
Jupyter Commands
pip3 --version ## Para revisar la version de pip
sudo pip3 install virtualenv ## Para instalar virtualenv
virtualenv primer_proyecto ## Para crear la carpeta del entorno virtual
cd primer_proyecto ## para acceder a la carpeta del entorno virtual
source bin/activate ## Para activar el entorno virtual
pip3 install jupyter ## para instalar jupyter dentro del entorno virtual
jupyter notebook ## Para levantar el servidor local con jupyter notebook
deactivate ## Para desactivar el entorno virtual
@danielmoralesp
danielmoralesp / python_exercises_part_i.md
Last active May 30, 2020 01:53
Python Exercises Part I

Python Exercises I

1- In Range

  • Cree una funcion llamada in_range() que recibe tres parametros num, lower, upper
  • La función debe retornar True si num es mayor o igual que lower y menor o igual que upper. De otra manera retorne False

2- Movie Review

  • Cree una funcion llamada movie_review() que tiene un parametro llamado rating
  • Si rating es menor o igual que 5 retorne "Avoid at all costs!".
  • Si el rating es entre 5 y 9retorne "This one was fun."

Ejercicios Python Parte I

1- Imprima su nombre usando el comando print().

2- Si su impresion uso comillas dobles " cambieles a comillas simples. Si usted uso comillas ' cambielas por comillas dobles.

3- Escriba la variable meal y asignele el valor de breakfast e imprimalo. Luego cambie el valor asignado por lunch e imprimalo.

4- Donde se encuentra el error de la siguiente linea de codigo? meal = "lunch, breakfast and "tea". Guarde en un string su respuesta y asignela a una variable llamada error_encontrado. Ahora en una nueva variabla llamada tipo_de_error asignele un string con el tipo de error: "sintax error" o "name error".