This file contains hidden or 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 numpy as np | |
import os | |
import wandb | |
from wandb.keras import WandbCallback | |
import tensorflow as tf | |
run = wandb.init() | |
config = run.config | |
config.dropout = 0.25 | |
config.dense_layer_nodes = 100 |
This file contains hidden or 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 tensorflow as tf | |
import wandb | |
# logging code | |
run = wandb.init() | |
config = run.config | |
# load data | |
(X_train, y_train), (X_test, y_test) = tf.keras.datasets.mnist.load_data() | |
img_width = X_train.shape[1] |
This file contains hidden or 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 tensorflow as tf | |
import wandb | |
# logging code | |
run = wandb.init() | |
config = run.config | |
# load data | |
(X_train, y_train), (X_test, y_test) = tf.keras.datasets.mnist.load_data() | |
img_width = X_train.shape[1] |
This file contains hidden or 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
from argparse import ArgumentParser | |
import wandb | |
import torch | |
from torch import nn | |
from torch.optim import SGD | |
from torch.utils.data import DataLoader | |
import torch.nn.functional as F | |
from torchvision.transforms import Compose, ToTensor, Normalize | |
from torchvision.datasets import MNIST |
This file contains hidden or 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 wandb | |
import matplotlib.pyplot as plt | |
from sklearn import datasets | |
wandb.init() | |
iris = datasets.load_iris() | |
X = iris.data[:, :2] # we only take the first two features. | |
y = iris.target |
This file contains hidden or 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
word_to_id = imdb.get_word_index() | |
word_to_id = {k: (v+3) for k, v in word_to_id.items()} | |
id_to_word = {value: key for key, value in word_to_id.items()} | |
id_to_word[0] = "" # Padding | |
id_to_word[1] = "" # Start token | |
id_to_word[2] = "�" # Unknown | |
id_to_word[3] = "" # End token | |
def decode(word): |
This file contains hidden or 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 wandb | |
import numpy as np | |
import xgboost as xgb | |
from keras.datasets import mnist | |
def wandb_callback(): | |
def callback(env): | |
for k, v in env.evaluation_result_list: | |
wandb.log({k: v}, commit=False) |
This file contains hidden or 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
declare -a voices=( | |
"Agnes" | |
"Albert" | |
"Alex" | |
"Alice" | |
"Alva" | |
"Amelie" | |
"Anna" | |
"Bad" | |
"Bahh" |
This file contains hidden or 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
Slides at http://bit.ly/lukas-qcom-course | |
Step 1) | |
Wandb is a logging program that will help you visualize neural network performance in the afternoon online. | |
Go to "https://app.wandb.ai/login?invited" and create an account. No need to follow further instructions. | |
Step 2) | |
On your server run: | |
cd ml-class/ | |
git pull origin master |
This file contains hidden or 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
ar arDrone = require('ar-drone'); | |
var client = arDrone.createClient(); | |
client.takeoff(); | |
client.after(5000, function() { | |
this.clockwise(0.5); | |
}).after(3000, function() { | |
this.stop(); | |
this.land(); |
NewerOlder