Neural Networks & AI Intelligence
Deep Learning is a part of Machine Learning that uses neural networks with multiple layers to learn patterns from data.
Machine Learning → Manual feature extraction Deep Learning → Automatic feature learning
Input Layer → Hidden Layers → Output Layer
ReLU → max(0, x) Sigmoid → 0 to 1 Softmax → probability output
Measures error between prediction and actual output
Algorithm to update weights using error
ANN → Basic neural network CNN → Image processing RNN → Sequence data (text, speech)
import tensorflow as tf model = tf.keras.Sequential([ tf.keras.layers.Dense(10, activation='relu'), tf.keras.layers.Dense(1) ]) model.compile(optimizer='adam', loss='mse') model.fit(X, y, epochs=10)
import torch.nn as nn model = nn.Sequential( nn.Linear(1, 10), nn.ReLU(), nn.Linear(10, 1) )