Multiklassenclassificatie

Introductie tot Deep Learning met Keras

Miguel Esteban

Data Scientist & Founder

Darten

Introductie tot Deep Learning met Keras

De dataset

Introductie tot Deep Learning met Keras

De dataset

Introductie tot Deep Learning met Keras

De architectuur

Introductie tot Deep Learning met Keras

De architectuur

Introductie tot Deep Learning met Keras

De architectuur

Introductie tot Deep Learning met Keras

De outputlaag

Introductie tot Deep Learning met Keras

Multiklassenmodel

# Instantiate a sequential model
# ...

# Add an input and hidden layer # ...
# Add more hidden layers # ...
# Add your output layer model.add(Dense(4, activation='softmax')
Introductie tot Deep Learning met Keras

Categorische cross-entropy

model.compile(optimizer='adam', loss='categorical_crossentropy')

Introductie tot Deep Learning met Keras

Een dataset voorbereiden

import pandas as pd
from tensorflow.keras.utils import to_categorical

# Load dataset
df = pd.read_csv('data.csv')

# Turn response variable into labeled codes df.response = pd.Categorical(df.response) df.response = df.response.cat.codes
# Turn response variable into one-hot response vector y = to_categorical(df.response)
Introductie tot Deep Learning met Keras

One-hot-encoding

Introductie tot Deep Learning met Keras

Laten we oefenen!

Introductie tot Deep Learning met Keras

Preparing Video For Download...