C.W.K.
Stream
Lesson 01 of 06 · published

Why Keras Is TF's High-Level API

~9 min · keras, history, keras3

Level 0Level 0
0 XP0/78 lessons0/17 achievements
0/100 XP to next level100 XP to go0% complete

Three ways to build the same network

Keras started as an independent library in 2015 — François Chollet wrote it on top of Theano with a clear philosophy: neural network code should be readable, modular, minimal. Google integrated Keras into TensorFlow as tf.keras in TF 2.0. From TF 2.16, tf.keras uses Keras 3 underneath — the multi-backend rewrite that runs on TF, PyTorch, or JAX.

Today both from tensorflow import keras and import keras refer to the same Keras 3. Use the latter for code you might want to run on a non-TF backend later.

Keras gives you three model-building APIs, each suited to different complexity levels:

APIBest forLimitation
SequentialLinear stacks, one input → one outputNo branches, no shared layers, no multi-I/O
FunctionalDAGs, residual connections, multi-I/ORequires explicit Input declaration
SubclassingCustom forward-pass logic, researchLess introspectable, harder to serialize

Code

두 import는 같은 곳을 가리킴·python
import tensorflow as tf
from tensorflow import keras
from tensorflow.keras import layers

# Or directly — preferred for backend-agnostic code:
import keras
from keras import layers

External links

Progress

Progress is local-only — sign in to sync across devices.
Spotted a bug or have feedback on this page?Report an Issue

Comments 0

🔔 Reply notifications (sign in)
Sign inPlease sign in to comment.

No comments yet — be the first.