Step 8: When to Go Deep

The right tool for the job

1 ExplorePlay below
2 ReadUnderstand
💡 ReflectThink deeper

When to go deep

Neural networks are powerful — but power without need is just complexity. Here's when depth helps and when simplicity wins.

📊
Tabular Data
CSV logs, features
Use: LogReg, RF, XGBoost
vs
🤖
Unstructured Data
Images, text, raw bytes
Use: Neural Networks

Use neural networks when:

  • Data is unstructured (images, text, audio, raw packets)
  • You have 100,000+ labelled samples
  • Simple models have plateaued and you need more capacity
  • You're doing transfer learning from pre-trained models

Use simple models when:

  • Data is tabular (structured features in rows/columns)
  • You have fewer than 10,000 samples
  • You need explainability (SOC analysts need to understand why)
  • You need fast inference and easy deployment

What you learned

StepConceptKey takeaway
0Single neuronweighted sum + bias + activation
1ActivationsReLU for hidden, sigmoid/softmax for output
2Architectureparams = (inputs × neurons) + neurons per layer
3Forward passData flows input → hidden → output in milliseconds
4Training loopEpochs of forward → loss → backward → update
5OverfittingStop when val accuracy peaks, not when train accuracy is perfect
6Baseline comparisonSimple models often match neural nets on tabular data

This lesson's model

NN AUC
97.0%
LogReg AUC
90.0%

Dataset

Samples
2,000
Attack rate
13.4%
Loading...

Think Deeper

Your team has 500 labelled malware samples and 50,000 benign samples. Should you use a neural network?

Probably not. With severe class imbalance and limited data, tree-based models (Random Forest, XGBoost) often work better. Neural networks need more data to generalise. Start simple, go deep only if the data supports it.
Cybersecurity tie-in: Most SOC ML tasks (alert triage, malware classification, user behaviour analytics) work on tabular data with limited labels. Start with Random Forest or XGBoost. Reserve neural networks for raw packet analysis, NLP on threat reports, or image-based malware detection.

Loading...