Eight scientific tutorials

Each native notebook contains the scientific case, training loop, evaluation, and figures. Open the version 2.0.0 notebook in GitHub or run it in Google Colab. The full scientific workloads are the default. NIF_SMOKE=1 selects a short development check and is separate from full training.

Native PyTorch tutorials

Tutorial

Scientific case

Main implementation concepts

Open

1

One-dimensional traveling wave

Configure NIF, train, save and restore weights, refine with L-BFGS.

Notebook / Colab

2

Multiscale wave

Use NIFMultiScale to represent high-frequency spatial structure.

Notebook / Colab

3

Cylinder-flow data from an adaptive mesh

Use NIFMultiScaleLastLayerParameterized to learn linear spatial bases.

Notebook / Colab

4

Input-output derivatives

Wrap a field model with JacobianLayer and HessianLayer.

Notebook / Colab

5

Large-scale record data

Create shards and stream batches from a one-million-row dataset.

Notebook / Colab

6

Multiscale fields with L1/L2 regularization

Penalize ParameterNet parameters and inspect a refined evaluation grid.

Notebook / Colab

7

Model compression

Magnitude pruning, dynamic int8 CPU inference, and inference export.

Notebook / Colab

8

Sobolev training of a multiscale field

Supervise spatial derivatives and evaluate field and derivative errors.

Notebook / Colab

The Native PyTorch validation and Controlled TensorFlow/PyTorch tutorial comparison pages retain the recorded error measurements and acceptance scope. Training points and additional spatial or temporal evaluation points are distinguished in those comparisons.

Original cases and compatibility notebooks

The original notebooks preserve the scientific definitions and historical outputs. The compatibility copies contain the pinned setup used for the historical backend. The following links preserve access to both sets.

Historical references

Tutorial

Original notebook

Compatibility notebook

1

Original

Compatibility

2

Original

Compatibility

3

Original

Compatibility

4

Original

Compatibility

5

Original

Compatibility

6

Original

Compatibility

7

Original

Compatibility

8

Original

Compatibility

See the original API documentation for that historical workflow. Use the native PyTorch links above for version 2.0.0.