Skip to content

Instantly share code, notes, and snippets.

View cosmincatalin's full-sized avatar
👻

Cosmin Catalin SANDA cosmincatalin

👻
View GitHub Profile
@cosmincatalin
cosmincatalin / object-counting-sagemaker-script.py
Created March 20, 2018 14:52
The first part of a SageMaker script for building an MXNet model that counts shapes in an image.
import logging
from pickle import load
import mxnet as mx
import numpy as np
from mxnet import autograd, nd, gluon
from mxnet.gluon import Trainer
from mxnet.gluon.loss import L2Loss
from mxnet.gluon.nn import Conv2D, MaxPool2D, Dropout, Flatten, Dense, Sequential
from mxnet.initializer import Xavier
@cosmincatalin
cosmincatalin / object-counting-sagemaker-script.py
Created March 21, 2018 10:08
The complete SageMaker script for building an MXNet model that counts shapes in an image.
import base64
import json
import logging
from pickle import load
import mxnet as mx
import numpy as np
from mxnet import autograd, nd, gluon
from mxnet.gluon import Trainer
from mxnet.gluon.loss import L2Loss
@cosmincatalin
cosmincatalin / voice-recognition-sagemaker-script.py
Created May 31, 2018 09:20
Voice Recognition Sagemaker Script (Full)
import base64
import glob
import json
import logging
import subprocess
import sys
import tarfile
import traceback
import uuid
import wave
@cosmincatalin
cosmincatalin / voice-recognition-sagmaker-notebook.ipynb
Created May 31, 2018 11:21
Voice Recognition SageMaker Notebook
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@cosmincatalin
cosmincatalin / MXNet to ONNX.ipynb
Created December 6, 2018 12:11
Modeling of an MXNet regression problem
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@cosmincatalin
cosmincatalin / mxnet-onnx-sagemaker-script.py
Created December 6, 2018 12:15
Training script used by SageMaker
import argparse
import logging
import os
from pickle import load
import mxnet as mx
import numpy as np
from mxnet import autograd, nd, gluon
from mxnet.contrib import onnx as onnx_mxnet
from mxnet.gluon.loss import L2Loss
@cosmincatalin
cosmincatalin / voice-recognition-sagemaker-script.py
Last active February 9, 2020 19:37
Voice Recognition Sagemaker Script (Part1)
import base64
import glob
import json
import logging
import subprocess
import sys
import tarfile
import traceback
import uuid
import wave
@cosmincatalin
cosmincatalin / notebook.ipynb
Last active August 18, 2020 21:42
The SageMaker attached notebook that allows building an MXNet model that counts shapes in an image
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@cosmincatalin
cosmincatalin / Shiny server with OAuth2.md
Last active October 27, 2022 10:59
Shiny community server with OAuth on Amazon EC2

Shiny community server with OAuth on Amazon EC2

Description

This is detailed description of how to set-up a Shiny server (community edition) on an AWS EC2 instance, behind an OAuth2 security layer (Google OAuth2 in this case, but it can be something else).

Prerequisites

  • A Google Developer account
  • An Amazon Web Services account
@cosmincatalin
cosmincatalin / install-rstudio-server.sh
Last active October 27, 2022 11:07
AWS EMR bootstrap to install RStudio Server along with sparklyr
#!/bin/bash
# These variables can be overwritten using the arguments below
VERSION="1.1.463"
# drwho is listed as user in YARN's Resource Manager UI.
USER="drwho"
# Depending on where the EMR cluster lives, you might have to change this to avoid security issues.
# To change the default password (and user), use the arguments bellow.
# If the cluster is not visible on the Internet, you can just leave the defaults for convenience.
PASS="tardis"