Skip to learning content

DATA SCIENCE PYTHON PLAYGROUND

Machine Learning · Learn / Refresh

← Neural Networks lessonsQUESTIONS · MODELS · EVIDENCE
Shared network concepts · ML-N-R1 · 15–20 MIN

Shared network retrieval

Retrieval 1

Exercises within this concept

  1. Retrieval 1Retrieve and applyCurrent exercise
  2. Retrieval 2Retrieve and apply
  3. Retrieval 3Retrieve and apply
Retrieval 1 · LINE24

A network diagram has 16 units in the first hidden layer and 8 in the next.

What does hidden_layer_sizes=(16,8) encode?

Retrieve earlier concepts before combining them.

This practice: Retrieve earlier concepts before combining them. Next: Retrieval 2 · Shared network retrieval.

Supporting concepts: Convergence, early stopping and validation →

Remember the idea

Use the inputs and evidence to recover the method. Hints and explained solutions remain collapsed; exact phrasing is not graded.

Retrieve earlier concepts before combining them.Candidate ACandidate BFitValidateCostCompare matching evidence; smaller error can cost more.
Schematic · Retrieve earlier concepts before combining them.Scroll the diagram horizontally if needed.
Hint 1 — Think

Recall which layers the tuple explicitly configures.

Hint 2 — Tools

Hidden-layer widths and task-dependent output layers.

Hint 3 — Approach

Map tuple positions to the diagram’s internal layers without including the output layer.

Explained solution

The tuple specifies hidden-layer widths. Output structure follows the prediction task.

The tuple specifies hidden-layer widths. Output structure follows the prediction task.

Helpful prior knowledge: Convergence, early stopping and validation These links are guidance, not locks.

Sources and API context

Examples run with this Playground’s scikit-learn 1.4.2 / Pyodide 0.26.4 runtime.

A network diagram has 16 units in the first hidden layer and 8 in the next. What does hidden_layer_sizes=(16,8) encode?